浏览代码

问题修改

suxinf 4 年之前
父节点
当前提交
e1acfefe0c
共有 4 个文件被更改,包括 7 次插入29 次删除
  1. 0 1
      src/request/api.js
  2. 2 7
      src/views/data/UploadRecord.vue
  3. 3 19
      src/views/data/components/UploadRecordDetail.vue
  4. 2 2
      vue.config.js

+ 0 - 1
src/request/api.js

@@ -10,7 +10,6 @@ axios.defaults.timeout = 5000;
 // 请求拦截器
 axios.interceptors.request.use((config) => {
     let baseData = config.data;
-    console.log('请求拦截', config);
     if (config.method.toLowerCase() === 'post') {
         config.data = qs.stringify(config.data);
     }

+ 2 - 7
src/views/data/UploadRecord.vue

@@ -156,7 +156,8 @@ export default {
           id: i,
           page: this.currentPage,
           rows: this.pageSize,
-          asc: this.asc
+          asc: this.asc,
+          informationName: this.tableData[i].informationName
         },
       });
     },
@@ -168,12 +169,9 @@ export default {
         data: data,
       })
         .then((res) => {
-          console.log(res);
           if (res.data && res.data.code === 200) {
             this.tableData = res.data.data;
             this.sum = res.data.count;
-          } else {
-            console.log(res);
           }
         })
         .catch((err) => {
@@ -182,7 +180,6 @@ export default {
     },
     // 下载资料接口
     selectInformationAgentList: function (data) {
-      console.log(data);
       let url =
         this.onlineUrl + "/dealerDownload?informationId=" + data.informationId;
       window.open(url);
@@ -198,13 +195,11 @@ export default {
           },
         })
           .then((res) => {
-            console.log(res, 222);
             if (res.data && res.data.code === 200) {
               alert("删除成功");
               resolve();
             } else {
               alert("删除失败,请重试");
-              console.log(res.message);
               rejecct();
             }
           })

+ 3 - 19
src/views/data/components/UploadRecordDetail.vue

@@ -101,11 +101,8 @@ export default {
   },
   mounted() {
     let req = {
-      page: this.page,
-      rows: this.rows,
-      asc: this.asc
+      informationName: this.informationName
     };
-    console.log(req);
     this.getFirmsUploadList(req);
     this.getAreaList();
   },
@@ -118,10 +115,7 @@ export default {
       tableData: [],
       optionValue: "",
       filesList: [],
-      index: (this.$route.query && this.$route.query.id) || "",
-      asc: (this.$route.query && this.$route.query.asc) || true,
-      rows: (this.$route.query && this.$route.query.rows) || 20,
-      page: (this.$route.query && this.$route.query.page) || 20,
+      informationName: (this.$route.query && this.$route.query.informationName) || 20,
       detailData: {},
       areaList: [],
       onlineUrl: env_url, //'http://8.140.188.129:8080'线上 //http://8.136.230.133:8080 //测试
@@ -207,7 +201,6 @@ export default {
     },
     // 导出 下载记录文件
     downloadExcel: function () {
-      console.log(this.detailData);
       let reqStr = "=" + this.detailData["id"];
       this.exportTem(reqStr);
     },
@@ -220,12 +213,10 @@ export default {
       })
         .then((res) => {
           if (res.data && res.data.code === 200) {
-            this.detailData = res.data.data[this.index];
+            this.detailData = res.data.data[0];
             let id = this.detailData["id"];
             let req = { informationId: id };
             this.selectInformationFileList(req);
-          } else {
-            console.log(res);
           }
         })
         .catch((err) => {
@@ -241,9 +232,6 @@ export default {
         .then((res) => {
           if (res.data && res.data.code === 200) {
             this.areaList = res.data.data;
-            console.log(this.areaList);
-          } else {
-            console.log(res);
           }
         })
         .catch((err) => {
@@ -266,8 +254,6 @@ export default {
           if (res.data && res.data.code === 200) {
             this.tableData = res.data.data;
             this.sum = res.data.count;
-          } else {
-            console.log(res);
           }
         })
         .catch((err) => {
@@ -284,8 +270,6 @@ export default {
         .then((res) => {
           if (res.data && res.data.code === 200) {
             this.filesList = res.data.data;
-          } else {
-            console.log(res);
           }
         })
         .catch((err) => {

+ 2 - 2
vue.config.js

@@ -21,8 +21,8 @@ module.exports = {
     outputDir: process.env.NODE_ENV === "development" ? 'devDist' : 'dist',
     configureWebpack: { // webpack 配置
         output: { // 输出重构  打包编译后的 文件名称  【模块名称.版本号.时间戳】
-            filename: `js/app.${Timestamp}.js`,
-            chunkFilename: `js/chunk-vendors.js.${Timestamp}.js`
+            filename: `js/app + ${Timestamp}.js`,
+            chunkFilename: `js/chunk-vendors + ${Timestamp}.js`
         },
     },
 };