Files
jobslink-user-clent/pages/login/blank.vue

71 lines
2.0 KiB
Vue
Raw Normal View History

2024-04-15 16:26:25 +08:00
<template>
<div class="app-container">
</div>
</template>
<script>
import {
mapGetters
} from 'vuex'
2024-10-09 10:14:51 +08:00
import {
GoLogin
} from '@/untils/AxiosUtils.js';
2024-04-15 16:26:25 +08:00
import website from '@/config/website.js'
export default {
data() {
return {}
},
computed: {
...mapGetters(['auth']),
},
onLoad(options) {
uni.showLoading({
2024-10-09 10:14:51 +08:00
title: '登录中'
2024-04-15 16:26:25 +08:00
})
2024-04-16 10:41:03 +08:00
if (options.token) {
2024-04-15 16:26:25 +08:00
const that = this
console.log(options)
this.$store.dispatch("LoginByUsername", {
username: 'admin',
password: "admin",
key: '',
code: '1111',
type: "account",
2024-04-16 10:41:03 +08:00
token: options.token,
2024-04-15 16:26:25 +08:00
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 {
2024-10-09 10:14:51 +08:00
// uni.reLaunch({
// url: '/pages/login/login'
// })
GoLogin()
2024-04-15 16:26:25 +08:00
}
},
method: {
callback(token) {
}
}
}
</script>
<style lang="scss" scoped>
.app-container {}
2024-03-20 20:21:25 +08:00
</style>