二级路由登录
This commit is contained in:
parent
8e53d92898
commit
4a6416de51
|
@ -161,9 +161,11 @@ instance.interceptors.response.use(
|
||||||
if (response.headers.redirect) {
|
if (response.headers.redirect) {
|
||||||
if (response.headers.redirect === '/#/login') {
|
if (response.headers.redirect === '/#/login') {
|
||||||
setAccessToken('')
|
setAccessToken('')
|
||||||
|
window.location.replace('/ucs/#/login')
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
location.reload()
|
location.reload()
|
||||||
}, 1000)
|
}, 1000)
|
||||||
|
return Promise.resolve()
|
||||||
}
|
}
|
||||||
window.location.replace(response.headers.redirect)
|
window.location.replace(response.headers.redirect)
|
||||||
return Promise.resolve()
|
return Promise.resolve()
|
||||||
|
|
Loading…
Reference in New Issue