diff --git a/src/utils/request.js b/src/utils/request.js index 6ffa7beb3e24084e0fa238ae45775efcbfc92039..094f7fc9df1b544025ec4ce283f084ac6ee81bde 100644 --- a/src/utils/request.js +++ b/src/utils/request.js @@ -5,6 +5,10 @@ function checkStatus(response) { if (response.status >= 200 && response.status < 300) { return response; } + notification.error({ + message: `请求错误 ${response.status}: ${response.url}`, + description: response.statusText, + }); const error = new Error(response.statusText); error.response = response; throw error;