|
@@ -32,7 +32,8 @@ router.beforeEach((to, from, next) => {
|
|
|
store.dispatch('SetInfo', userInfo)
|
|
|
} else {
|
|
|
store.dispatch('Logout').then(() => {
|
|
|
- next({ path: '/user/login', query: { redirect: to.fullPath } })
|
|
|
+ // next({ path: '/user/login', query: { redirect: to.fullPath } })
|
|
|
+ next({ path: '/user/login' })
|
|
|
})
|
|
|
}
|
|
|
console.log(store.getters.roles)
|
|
@@ -45,7 +46,8 @@ router.beforeEach((to, from, next) => {
|
|
|
if (roles.permissionList.length == 0 || !roles) {
|
|
|
store.dispatch('Logout').then(() => {
|
|
|
store.dispatch('ResetRoutes').then(() => {
|
|
|
- next({ path: '/user/login', query: { redirect: to.fullPath } })
|
|
|
+ // next({ path: '/user/login', query: { redirect: to.fullPath } })
|
|
|
+ next({ path: '/user/login' })
|
|
|
})
|
|
|
})
|
|
|
} else {
|
|
@@ -70,7 +72,8 @@ router.beforeEach((to, from, next) => {
|
|
|
description: '请求用户信息失败,请重试'
|
|
|
})
|
|
|
store.dispatch('Logout').then(() => {
|
|
|
- next({ path: '/user/login', query: { redirect: to.fullPath } })
|
|
|
+ // next({ path: '/user/login', query: { redirect: to.fullPath } })
|
|
|
+ next({ path: '/user/login' })
|
|
|
})
|
|
|
})
|
|
|
} else {
|