Commit 9b2efc47 by liangqi

添加跨域支持

parent 7e7a6b15
...@@ -36,6 +36,13 @@ import '@/assets/less/style3.less' ...@@ -36,6 +36,13 @@ import '@/assets/less/style3.less'
import '@/assets/less/style4.less' import '@/assets/less/style4.less'
axios.defaults.withCredentials = false; axios.defaults.withCredentials = false;
axios.interceptors.request.use(
config=>{
config.headers = {
'Content-Type': 'application/x-www-form-urlencoded'
}
}
);
axios.defaults.timeout = 50000; axios.defaults.timeout = 50000;
axios.interceptors.request.use(config => { axios.interceptors.request.use(config => {
return checkToken().then(function(res) { return checkToken().then(function(res) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment