bug fix:单点登录登出问题

This commit is contained in:
lizhicheng2 2022-09-19 13:04:27 +08:00
parent 6ef87c3c79
commit f3973fe28d
2 changed files with 9 additions and 8 deletions

View File

@ -100,6 +100,7 @@ instance.interceptors.response.use(
console.log('接口返回', response) console.log('接口返回', response)
console.log('接口返回headers', response.headers) console.log('接口返回headers', response.headers)
console.log('接口返回REDIRECT', response.headers.redirect) console.log('接口返回REDIRECT', response.headers.redirect)
debugger
response['Access-Control-Expose-Headers'] = 'redirect' response['Access-Control-Expose-Headers'] = 'redirect'
const { const {
code, code,

View File

@ -161,14 +161,14 @@
localStorage.removeItem('DetailsPageconetent') localStorage.removeItem('DetailsPageconetent')
window.sessionStorage.setItem('visits', JSON.stringify([])) window.sessionStorage.setItem('visits', JSON.stringify([]))
// 西 // 西
if (!whoShow1.itShowXiHaiAn) { // if (!whoShow1.itShowXiHaiAn) {
if (recordRoute) { // if (recordRoute) {
const fullPath = route.fullPath // const fullPath = route.fullPath
router.push(`/login?redirect=${fullPath}`) // router.push(`/login?redirect=${fullPath}`)
} else { // } else {
router.push('/login') // router.push('/login')
} // }
} // }
} }
// //
const goToHome = () => { const goToHome = () => {