|
|
|
|
@ -65,7 +65,8 @@ axios.interceptors.response.use(res => { |
|
|
|
|
//如果在白名单里则自行catch逻辑处理
|
|
|
|
|
if (statusWhiteList.includes(status)) return Promise.reject(res); |
|
|
|
|
//如果是401则跳转到登录页面
|
|
|
|
|
if (status === 401) store.dispatch('FedLogOut').then(() => router.push({path: '/newlogin'})); |
|
|
|
|
// if (status === 401) store.dispatch('FedLogOut').then(() => router.push({path: '/newlogin'}));
|
|
|
|
|
if (status === 401) store.dispatch('FedLogOut').then(() => {window.location.href="http://jhoa.qd.gov.cn/Default.aspx";}); |
|
|
|
|
// 如果请求为非200否者默认统一处理
|
|
|
|
|
if(res.data.error != undefined && res.config.params != undefined && res.config.params.grant_type != undefined && res.config.params.grant_type == 'yawei') { |
|
|
|
|
return Promise.reject(res.data) |
|
|
|
|
|