From ed2f5cbcb482a22fbf799cf14ff3d3152669e7ac Mon Sep 17 00:00:00 2001
From: zouyu <2723363702@qq.com>
Date: 星期三, 27 九月 2023 18:17:02 +0800
Subject: [PATCH] modified: src/assets/api/controller.js modified: src/components/view/mbom.vue modified: src/components/view/standard.vue
---
src/main.js | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/src/main.js b/src/main.js
index f5b6bda..9a81a52 100644
--- a/src/main.js
+++ b/src/main.js
@@ -23,7 +23,11 @@
Vue.use(qs);
Vue.use(api);
-const javaApi = 'http://localhost:8001/'
+const javaApi = 'http://localhost:8001'
+
+// const javaApi = 'http://127.0.0.1:8001/'
+
+
axios.defaults.baseURL = javaApi
axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded;charset=UTF-8'
@@ -56,12 +60,16 @@
// console.log(config.data)
}
+
return config
}, function(error) {
return Promise.reject(error)
})
axios.interceptors.response.use(res => {
+ if(res.config.responseType === 'blob'){
+ return res;
+ }
return res.data
}, async function(err) {
if (JSON.stringify(err).indexOf('timeout of') > -1) {
@@ -117,4 +125,4 @@
el: '#app',
router,
render: h => h(App)
-});
\ No newline at end of file
+});
--
Gitblit v1.9.3