This commit is contained in:
熊成强 2020-11-20 14:25:11 +08:00
parent 164daf9bf3
commit e112f6891f
2 changed files with 1 additions and 3 deletions

View File

@ -47,14 +47,11 @@ export default {
} }
}, },
async mounted () { async mounted () {
const a = await this.GET_DEPLIST()
console.log('a: ', a)
}, },
methods: { methods: {
onCancel () { onCancel () {
}, },
...mapActions(['GET_DEPLIST']),
...mapMutations(['SET_USER_INFO']), ...mapMutations(['SET_USER_INFO']),
// //
handleGetDingtalkCode () { handleGetDingtalkCode () {

View File

@ -45,6 +45,7 @@ router.beforeEach(async (to, from, next) => {
if (res === 1) { if (res === 1) {
console.log('res: ', res) console.log('res: ', res)
let res1 = await store.dispatch('GET_USERINFO') let res1 = await store.dispatch('GET_USERINFO')
await store.dispatch('GET_DEPLIST')
console.log('res1: ', res1) console.log('res1: ', res1)
if (res1 === 1) next() if (res1 === 1) next()
} else { } else {