forked from github/dataease
Merge pull request #4481 from dataease/pr@dev@fix_router_history
fix(登录): 退出后重新登录路由到历史页面
This commit is contained in:
commit
babb8a376d
@ -365,7 +365,7 @@ export default {
|
||||
if (result !== 'success' && result !== 'fail') {
|
||||
window.location.href = result
|
||||
} else {
|
||||
this.$router.push('/login')
|
||||
this.$router.push(`/login?redirect=${this.$route.fullPath}`)
|
||||
}
|
||||
},
|
||||
loadUiInfo() {
|
||||
|
@ -118,8 +118,7 @@ router.beforeEach(async(to, from, next) => routeBefore(() => {
|
||||
next()
|
||||
} else {
|
||||
// other pages that do not have permission to access are redirected to the login page.
|
||||
// next(`/login?redirect=${to.path}`)
|
||||
next('/login')
|
||||
next(`/login?redirect=${to.path}`)
|
||||
NProgress.done()
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user