| | |
| | | /* //POST传参序列化(添加请求拦截器) */ |
| | | Axios.interceptors.request.use( |
| | | (config) => { |
| | | console.log(9898) |
| | | console.log(config) |
| | | |
| | | if ((config.method === "post" && sessionStorage.getItem("clusterId")) || sessionStorage.getItem("devId")) { |
| | | if (!config.data) { |
| | | config.data = {} |
| | |
| | | return config |
| | | }, |
| | | (error) => { |
| | | console.log("请求错误") |
| | | console.log(error) |
| | | console.log("请求错误", error) |
| | | |
| | | /* Message({ |
| | | showClose: true, |
| | |
| | | var disposition = res.headers["content-disposition"] |
| | | if (disposition) { |
| | | var fileName = disposition.substring(disposition.indexOf("=") + 1) |
| | | console.log(res) |
| | | |
| | | return { |
| | | fileName: fileName, |
| | |
| | | /* //return res.data ? res.data : {}; */ |
| | | }, |
| | | (error) => { |
| | | console.log("响应错误") |
| | | console.log(error) |
| | | console.log("响应错误", error) |
| | | let errJson: any = { |
| | | success: false |
| | | } |