luobang 2 年之前
父节点
当前提交
9251d71c14

+ 2 - 2
build/utils.js

@@ -15,10 +15,10 @@ const devPathSrc = path.resolve(__dirname, "../../../src"); // node_modules应
 // ['index','appoint','configManager','homepage',''inward,'queue','RMS','sale','serviceManager','SporadicManage'
 //       统计报表       组织机构/系统管理 采购  仓储
 //  'statisticalReport','systemConfig','TMS','WMS','workFlow']
-// let devModules = ["index", "appoint", "statisticalReport"];
+let devModules = ["index", "appoint", "statisticalReport"];
 // let devModules = ["index", "statisticalReport", "appoint", "TMS"];
 // let devModules = ["index", "statisticalReport", "TMS", "appoint"];
-let devModules = ["all"];
+// let devModules = ["all"];
 
 // let devModules = ['index','appoint','sale','statisticalReport','RMS','TMS','WMS']
 // let devModules = ["index", "ADMINISTRATORS", "RMS"];

+ 2 - 2
config/index.js

@@ -65,9 +65,9 @@ let proxyTable = {
   },
   // 所有数据的请求域名地址
   "/api/v1": {
-    target: "http://172.16.33.166:80",
+    // target: "http://172.16.33.166:80",
     // target: "http://localhost:8080",
-    // target: "http://192.168.1.105:8080",
+    target: "http://192.168.1.105:8080",
     // target: "http://192.168.1.106:8080",
     ws: true,
     pathRewrite: {

+ 78 - 7
src/views/statisticalReport/components/salesLogisticsStatistics/saleSteelAllReport.vue

@@ -50,6 +50,7 @@
         :span-method="objectSpanMethod"
         border
         stripe
+        @filter-change="filterChange"
         style="width: 100%; margin-top: 20px"
         max-height="500px"
         @cell-click="cellClik"
@@ -106,6 +107,10 @@
           label="车牌号"
           align="center"
           width="250px"
+          :filter-multiple="true"
+          :filters="filterData()"
+          :filter-method="filterTag"
+          @reset="resetChange"
         >
           <template slot-scope="scope">
             <el-autocomplete
@@ -124,7 +129,12 @@
             >
           </template>
         </el-table-column>
-        <el-table-column prop="capacityTel" label="司机电话" width="250px">
+        <el-table-column
+          prop="capacityTel"
+          label="司机电话"
+          width="250px"
+          align="center"
+        >
           <template slot-scope="scope">
             <el-input
               style="width:120px"
@@ -202,17 +212,35 @@
           :width="flexColumnWidth('receiptAddress', tableData, 'max')"
         >
         </el-table-column>
-        <el-table-column prop="orderNo" label="运输订单号"> </el-table-column>
-        <el-table-column prop="saler" label="业务员"> </el-table-column>
-        <el-table-column prop="shipperName" label="发货单位"> </el-table-column>
+        <el-table-column
+          prop="orderNo"
+          label="运输订单号"
+          :width="flexColumnWidth('orderNo', tableData, 'max')"
+          align="center"
+        >
+        </el-table-column>
+        <el-table-column prop="saler" label="业务员" align="center">
+        </el-table-column>
+        <el-table-column
+          prop="shipperName"
+          label="发货单位"
+          :width="flexColumnWidth('shipperName', tableData, 'max')"
+          align="center"
+        >
+        </el-table-column>
         <el-table-column prop="truckNo" label="车序号"> </el-table-column>
         <el-table-column prop="consigneeTel" label="收货客户电话">
         </el-table-column>
-        <el-table-column prop="isSelfMention" label="是否自提">
+        <el-table-column prop="isSelfMention" label="是否自提" align="center">
         </el-table-column>
         <el-table-column prop="saleOrderStatus" label="销售订单状态">
         </el-table-column>
-        <el-table-column label="操作" fixed="right" width="200px">
+        <el-table-column
+          label="操作"
+          fixed="right"
+          width="120px"
+          align="center"
+        >
           <template slot-scope="scope">
             <el-button
               type="text"
@@ -271,11 +299,55 @@ export default {
       ]
     };
   },
+  computed: {
+    filterData() {
+      return function() {
+        let obj = [];
+        //找到对应的数据,并添加到obj
+        this.tableData.filter(item => {
+          let map = {};
+          if (
+            item.capacityNo != null &&
+            item.capacityNo != "" &&
+            item.capacityNo != "null"
+          ) {
+            map.text = item.capacityNo;
+            map.value = item.capacityNo;
+            obj.push(map);
+          }
+        });
+        return this.deWeight(obj);
+      };
+    }
+  },
   created() {},
   mounted() {
     this.getSteelReport();
   },
   methods: {
+    resetChange() {
+      console.log("wczhil");
+    },
+    filterChange() {
+      console.log("11");
+    },
+    filterTag(value, row, column) {
+      console.log(value);
+      console.log(row);
+      console.log(column);
+    },
+    // 数组对象去重
+    deWeight(arr) {
+      for (var i = 0; i < arr.length - 1; i++) {
+        for (var j = i + 1; j < arr.length; j++) {
+          if (arr[i].text == arr[j].text) {
+            arr.splice(j, 1);
+            j--;
+          }
+        }
+      }
+      return arr;
+    },
     cellClik(row, column, cell, event) {
       if (column.property == "capacityNo") {
         this.$set(row, "isCapacityShow", 1);
@@ -448,7 +520,6 @@ export default {
         }
       });
     },
-
     //记录每一行的合并数
     getSpanArr(data) {
       //每次调用方法初始化