|
@@ -52,7 +52,7 @@ service.interceptors.request.use(config => {
|
|
|
|
|
|
// response interceptor
|
|
|
service.interceptors.response.use((response) => {
|
|
|
- // console.log(response, 'responseresponseresponse')
|
|
|
+ console.log(response, 'responseresponseresponse')
|
|
|
if (response.data.status == '-1') {
|
|
|
notification.error({
|
|
|
message: '提示',
|
|
@@ -64,6 +64,13 @@ service.interceptors.response.use((response) => {
|
|
|
})
|
|
|
}, 2000)
|
|
|
}
|
|
|
+ if ((response.data.status == '900' || response.data.status == '500') && window.location.pathname != '/user/login') {
|
|
|
+ notification.destroy()
|
|
|
+ notification.error({
|
|
|
+ message: '提示',
|
|
|
+ description: response.data.message
|
|
|
+ })
|
|
|
+ }
|
|
|
return response.data
|
|
|
}, err)
|
|
|
|