2024-03-20 20:21:25 +08:00
|
|
|
<template>
|
|
|
|
|
<div class="app-container">
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
import {
|
|
|
|
|
mapGetters
|
|
|
|
|
} from 'vuex'
|
|
|
|
|
import website from '@/config/website.js'
|
|
|
|
|
export default {
|
|
|
|
|
data() {
|
|
|
|
|
return {}
|
|
|
|
|
},
|
|
|
|
|
computed: {
|
|
|
|
|
...mapGetters(['auth']),
|
|
|
|
|
},
|
|
|
|
|
onLoad(options) {
|
|
|
|
|
uni.showLoading({
|
2024-03-26 16:42:06 +08:00
|
|
|
title: ''
|
2024-03-20 20:21:25 +08:00
|
|
|
})
|
|
|
|
|
if(options.token) {
|
|
|
|
|
const that = this
|
|
|
|
|
console.log(options)
|
|
|
|
|
this.$store.dispatch("LoginByUsername", {
|
|
|
|
|
username: 'admin',
|
|
|
|
|
password: "admin",
|
|
|
|
|
key: '',
|
|
|
|
|
code: '1111',
|
|
|
|
|
type: "account",
|
|
|
|
|
token: options.token,
|
|
|
|
|
tenantId: website.tenantId
|
|
|
|
|
}).then((resp) => {
|
|
|
|
|
console.log('123', resp)
|
|
|
|
|
this.$store.dispatch('refreshAuthState').then(() => {
|
|
|
|
|
that.loading = false
|
|
|
|
|
var auth = this.auth
|
|
|
|
|
uni.hideLoading()
|
|
|
|
|
if (!auth.bankCardState) {
|
|
|
|
|
that.goSign(0)
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
uni.switchTab({
|
|
|
|
|
url: '/pages/index/index'
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}).catch((err) => {
|
|
|
|
|
this.loading = false
|
|
|
|
|
// this.$refs.code.refushCode()
|
|
|
|
|
});
|
|
|
|
|
} else {
|
|
|
|
|
uni.reLaunch({
|
|
|
|
|
url: '/pages/login/login'
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
method: {
|
|
|
|
|
callback(token) {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
|
.app-container{
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
</style>
|