fix:bug定位

This commit is contained in:
zyh
2023-03-09 17:25:29 +08:00
parent 36dc0b17da
commit 9aada00e4f
3 changed files with 6 additions and 6 deletions

View File

@@ -181,8 +181,8 @@ export default {
logout () {
this.$get('logout').then(() => {
this.logoutSuccess()
// document.location.href = '/'
this.$router.push('/login')
window.location.href = '/'
// this.$router.push('/login')
})
},
showPinDialog () {

View File

@@ -103,11 +103,11 @@ axios.interceptors.response.use(
return response
}
if (licenceErrorCode.indexOf(response.data.code) !== -1 && noJumpPath.indexOf(window.location.pathname) == -1) {
sessionStorage.setItem('nz-previous-page', router.currentRoute.fullPath)
sessionStorage.setItem('nz-previous-page', router.currentRoute.fullPath + '1')
window.location.href = '/'
} else if (response.status === 200) {
if (accountErrorCode.indexOf(response.data.code) !== -1 && noJumpPath.indexOf(window.location.pathname) == -1) {
sessionStorage.setItem('nz-previous-page', router.currentRoute.fullPath)
sessionStorage.setItem('nz-previous-page', router.currentRoute.fullPath + '2')
window.location.href = '/'
}
} else {

View File

@@ -149,7 +149,7 @@ router.beforeEach((to, from, next) => {
resolve()
} else {
localStorage.removeItem('nz-token')
sessionStorage.setItem('nz-previous-page', to.fullPath)
sessionStorage.setItem('nz-previous-page', to.fullPath + '5')
next({ path: '/login' })
}
})
@@ -180,7 +180,7 @@ router.beforeEach((to, from, next) => {
if (loginWhiteList.indexOf(to.path) !== -1) {
next()
} else {
sessionStorage.setItem('nz-previous-page', to.fullPath)
sessionStorage.setItem('nz-previous-page', to.fullPath + '6')
next({ path: '/login' })
}
}