flat: 添加30分钟退出功能
This commit is contained in:
@@ -60,8 +60,12 @@ axios.interceptors.response.use(
|
||||
//如果在白名单里则自行catch逻辑处理
|
||||
if (statusWhiteList.includes(status)) return Promise.reject(res);
|
||||
//如果是401则跳转到登录页面
|
||||
if (status === 401)
|
||||
store.dispatch('FedLogOut').then(() => router.push({path: '/login'}));
|
||||
if (status === 401) {
|
||||
store.dispatch('FedLogOut').then(() => {
|
||||
window.location.href = 'http://10.160.7.216:9920/casserver/login?service=http://10.165.0.77/manage/login&stService=http%3A%2F%2F10.165.0.77%2Fmanage%2Flogin'
|
||||
});
|
||||
// store.dispatch('FedLogOut').then(() => router.push({path: '/login'}));
|
||||
}
|
||||
// 如果请求为500统一处理
|
||||
const err = new Error(message)
|
||||
err.response = res
|
||||
|
||||
Reference in New Issue
Block a user