|
|
@@ -9,7 +9,7 @@ axios.interceptors.request.use(
|
|
|
config.headers.Authorization = `${token}`;
|
|
|
} else {
|
|
|
//未登录
|
|
|
- // window.location.hash = "/login";
|
|
|
+ window.location.hash = "/login";
|
|
|
}
|
|
|
// }
|
|
|
return config;
|
|
|
@@ -39,7 +39,7 @@ axios.interceptors.response.use(function (response) {
|
|
|
}, function (error) {
|
|
|
// 对响应错误做点什么
|
|
|
if (error.request.status == 403) {
|
|
|
- // window.location.hash = "/login";
|
|
|
+ window.location.hash = "/login";
|
|
|
}
|
|
|
// console.log(Object.getOwnPropertyNames(error))
|
|
|
// console.log(error.request,error.message)
|