1.7 优化
This commit is contained in:
@@ -132,6 +132,6 @@ a:hover {
|
|||||||
height: 32px;
|
height: 32px;
|
||||||
width: 135px;
|
width: 135px;
|
||||||
display: block;
|
display: block;
|
||||||
margin: 0 auto;
|
//margin: 0 auto;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -45,9 +45,16 @@ service.interceptors.response.use(
|
|||||||
try {
|
try {
|
||||||
code = error.response.data.status
|
code = error.response.data.status
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
if (error.toString().indexOf('timeout')) {
|
if (error.toString().indexOf('Error: timeout') !== -1) {
|
||||||
Notification.error({
|
Notification.error({
|
||||||
title: '请求超时',
|
title: '请求超时,请重试',
|
||||||
|
duration: 2500
|
||||||
|
})
|
||||||
|
return Promise.reject(error)
|
||||||
|
}
|
||||||
|
if (error.toString().indexOf('Error: Network Error') !== -1) {
|
||||||
|
Notification.error({
|
||||||
|
title: '网络错误,请联系网站管理员恢复',
|
||||||
duration: 2500
|
duration: 2500
|
||||||
})
|
})
|
||||||
return Promise.reject(error)
|
return Promise.reject(error)
|
||||||
|
|||||||
Reference in New Issue
Block a user