fix: 修复cas单点登录

This commit is contained in:
dj
2024-12-15 15:31:23 +08:00
parent 6df2fa98c1
commit 6e839fb255
2 changed files with 3 additions and 2 deletions

View File

@@ -233,8 +233,8 @@ router.beforeEach(async (to, form, next) => {
path: path, path: path,
query: query query: query
})) }))
window.location.href = `${window.location.origin}/api/auth/cas/login` // window.location.href = `${window.location.origin}/api/auth/cas/login`
// next({path: '/api/auth/cas/login'}) next({path: '/api/auth/cas/login'})
} }
} else { } else {
if (to.path === '/login' || to.path === '/cas/login') { if (to.path === '/login' || to.path === '/cas/login') {

View File

@@ -57,6 +57,7 @@ serveice.interceptors.response.use(response => {
path: path, path: path,
query: query query: query
})) }))
//todo 跳转登录页
window.location.href = `${window.location.origin}/api/auth/cas/login` window.location.href = `${window.location.origin}/api/auth/cas/login`
// }) // })
return Promise.reject('会话已过期,请重新登录') return Promise.reject('会话已过期,请重新登录')