This commit is contained in:
熊成强 2020-11-20 14:34:03 +08:00
parent e112f6891f
commit 4a0cf97b22
2 changed files with 9 additions and 5 deletions

View File

@ -1,8 +1,8 @@
<template> <template>
<div id="app"> <div id="app">
<!-- <div v-if="!dd.pc && !dd.other" class="pc commonFont"> <div v-if="!dd.pc && !dd.other" class="pc commonFont">
请移步PC端操作 请移步PC端操作
</div> --> </div>
<router-view class="main"/> <router-view class="main"/>
</div> </div>
</template> </template>
@ -19,7 +19,10 @@ export default {
name: 'App', name: 'App',
data () { data () {
return { return {
dd, dd: {
pc: true,
other: true
},
active: true, active: true,
fullPage: true, fullPage: true,
dingCode: '', dingCode: '',
@ -47,6 +50,7 @@ export default {
} }
}, },
async mounted () { async mounted () {
this.dd = dd
}, },
methods: { methods: {
onCancel () { onCancel () {

View File

@ -45,7 +45,6 @@ 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 {
@ -57,5 +56,6 @@ router.beforeEach(async (to, from, next) => {
} }
}) })
router.afterEach(() => { router.afterEach(async () => {
await store.dispatch('GET_DEPLIST')
}) })