luobang 1 yıl önce
ebeveyn
işleme
6bf33351ac

+ 1 - 1
build/utils.js

@@ -19,7 +19,7 @@ const devPathSrc = path.resolve(__dirname, '../../../src') // node_modules应用
 // let devModules = ['all']
 // let devModules = ['index']
 let devModules = ['all']
-// let devModules = ['index', 'ADMINISTRATORS']
+// let devModules = ['index', 'statisticalReport', 'appoint', 'sale', 'WMS']
 
 if (pathSrc.indexOf('node_modules') > -1) {
   devModules = require('../../../cors.js').devModules

+ 3 - 3
config/index.js

@@ -72,7 +72,7 @@ let proxyTable = {
   },
   // 所有数据的请求域名地址
   '/api/v1': {
-    target: 'http://192.168.3.81:80',
+    target: 'http://172.16.33.166:80',
     // target: 'http://localhost:8080',
     // target: 'http://192.168.1.104:8080',
     ws: true,
@@ -81,8 +81,8 @@ let proxyTable = {
     }
   },
   '/views/api/v1': {
-    //target: "http://172.16.33.166:80",
-    target: 'http://192.168.3.81:80',
+    target: 'http://172.16.33.166:80',
+    // target: 'http://localhost:8080',
     ws: true,
     pathRewrite: {
       '^/views/api/v1': '/api/v1'

+ 1 - 0
package.json

@@ -41,6 +41,7 @@
     "jspdf": "^2.5.1",
     "jssha": "^3.2.0",
     "lay-excel": "^1.7.6",
+    "marked": "5.0.5",
     "mathjs": "^10.6.4",
     "object-assign": "^4.1.1",
     "qrcodejs2": "0.0.2",

+ 1 - 1
src/components/main.vue

@@ -271,7 +271,7 @@
               class="ifCompany el-dropdown-link"
               v-if="companys.length === 1"
             >
-              湖南视拓信息技术股份有限公司智慧物流平台
+              {{ companyName }}
             </span>
             <el-dropdown trigger="click" @command="selectComPany" v-else>
               <span class="el-dropdown-link">

+ 15 - 15
src/utils/exportExcelAdvanced.JS

@@ -5,20 +5,20 @@
  */
 // 导出Excel全局组件
 export function exportExcelAdvanced(tableTitle, tableColumnData, tableData) {
-    let tHeader = [];
-    let filterVal = [];
-    tableColumnData.forEach(e => {
+  let tHeader = []
+  let filterVal = []
+  tableColumnData.forEach(e => {
     if (tHeader.indexOf(e.label) === -1) {
-          tHeader.push(e.label);
-    };
+      tHeader.push(e.label)
+    }
     if (filterVal.indexOf(e.prop) === -1) {
-          filterVal.push(e.prop);
-    };
-    });
-    // this.downloadLoading = true;
-    require.ensure([], () => {
-    const { exportJsonToExcel } = require('@/assets/excel/Export2Excel.js');
-    let data = tableData.map(v => filterVal.map(j => v[j]));
-    exportJsonToExcel(tHeader, data, tableTitle);
-    });
- }
+      filterVal.push(e.prop)
+    }
+  })
+  // this.downloadLoading = true;
+  require.ensure([], () => {
+    const { exportJsonToExcel } = require('@/assets/excel/Export2Excel.js')
+    let data = tableData.map(v => filterVal.map(j => v[j]))
+    exportJsonToExcel(tHeader, data, tableTitle)
+  })
+}

+ 191 - 165
src/views/WMS/components/steel/bar2_steel/bar2_steel_inboundReal.vue

@@ -3,7 +3,11 @@
   <div class="steel_inbound">
     <div class="sache">
       <span>入库时间:</span>
-      <el-date-picker v-model="startTime" type="datetime" placeholder="选择日期">
+      <el-date-picker
+        v-model="startTime"
+        type="datetime"
+        placeholder="选择日期"
+      >
       </el-date-picker>
       <span>至</span>
       <el-date-picker v-model="endTime" type="datetime" placeholder="选择日期">
@@ -22,272 +26,294 @@
       </el-button> -->
     </div>
     <div class="table">
-      <dilTable v-bind.sync="options" @selection-change="selectionChange" ref="table">
+      <dilTable
+        v-bind.sync="options"
+        @selection-change="selectionChange"
+        ref="table"
+      >
         <el-table-column fixed="right" label="操作" width="150">
-								<template slot-scope="scope">
-									<el-button type="text" size="mini" @click="deleteInbound(scope)">
-										删除
-									</el-button>
-								</template>
-				</el-table-column>
+          <template slot-scope="scope">
+            <el-button type="text" size="mini" @click="deleteInbound(scope)">
+              删除
+            </el-button>
+          </template>
+        </el-table-column>
       </dilTable>
     </div>
   </div>
 </template>
 
 <script>
-import { sjTime } from "@/utils/sharedJsFile";
-import { getCookie } from '@/utils/util.js';
+import { sjTime } from '@/utils/sharedJsFile'
+import { getCookie } from '@/utils/util.js'
 export default {
-  data(){
-    return{
-      inputText:"",
+  data() {
+    return {
+      inputText: '',
       startTime: null,
       endTime: null,
-      region: "0",
-      options:{
+      region: '0',
+      options: {
         // first请求数据的地址
-        requestUrl: "/api/v1/wms/getWmsInboundResults?apiId=450&warehouseId="+2,
+        requestUrl:
+          '/api/v1/wms/getWmsInboundResults?apiId=450&warehouseId=' + 2
         // selectionType: "select",
         // mapList: [],
-      },
+      }
     }
   },
-  methods:{
-    deleteInbound(scope){
-       this.$confirm("是否删除", "提示", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "warning",
-        center: true,
+  methods: {
+    deleteInbound(scope) {
+      this.$confirm('是否删除', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning',
+        center: true
       })
         .then(() => {
           this.axios
-            .post("/api/v1/wms/undoInbound?inboundId=" + scope.row.inboundId)
-            .then((res) => {
-              console.log("res.data.code",res.data.code)
+            .post('/api/v1/wms/undoInbound?inboundId=' + scope.row.inboundId)
+            .then(res => {
+              console.log('res.data.code', res.data.code)
               if (res.data.code == 200) {
                 this.$message({
-                  type: "success",
-                  message: "删除成功!",
-                });     
-                this.$router.go(0);
+                  type: 'success',
+                  message: '删除成功!'
+                })
+                this.$router.go(0)
               } else {
                 this.$message({
-                  message: "删除失败",
-                  type: "warning",
-                });
+                  message: '删除失败',
+                  type: 'warning'
+                })
               }
-            });
+            })
         })
         .catch(() => {
           this.$message({
-            type: "info",
-            message: "删除操作已取消!",
-          });
-        });
-    },
+            type: 'info',
+            message: '删除操作已取消!'
+          })
+        })
     },
+
     // 获取当前月份的最后一天
-    getdaysinmonth(year,month){
-      month = parseInt(month,10)+1;
-      let days = 0;
-      month = month -1;
-      console.log("othermonth"+month)
-      console.log("otheryear"+year);
+    getdaysinmonth(year, month) {
+      month = parseInt(month, 10) + 1
+      let days = 0
+      month = month - 1
+      console.log('othermonth' + month)
+      console.log('otheryear' + year)
       // 根据月份获取对应的天数
-      if(month == 2){
-        days = year % 4 == 0?29:28;
-      }else if(month == 1||month == 3||month == 5||month == 7||month == 8||month == 10||month == 12){
-        days = 31;
-      }else{
-        days = 30;
+      if (month == 2) {
+        days = year % 4 == 0 ? 29 : 28
+      } else if (
+        month == 1 ||
+        month == 3 ||
+        month == 5 ||
+        month == 7 ||
+        month == 8 ||
+        month == 10 ||
+        month == 12
+      ) {
+        days = 31
+      } else {
+        days = 30
       }
-      console.log("otherdays"+days)
-      return days;
+      console.log('otherdays' + days)
+      return days
     },
-    onclick(){
-      let startTime = null;
-      let endTime = null;
-      
+    onclick() {
+      debugger
+      let startTime = null
+      let endTime = null
       // 判断用户有没有班次,有班次则提供默认时间
-      if(this.region!=null){
-        let date =null;
-        let date2 =null;
-        let year = null;
-        let month =null;
-        let day = null;
-        let year2 = null;
-        let month2 =null;
-        let day2 = null;
+      if (this.region != null) {
+        let date = null
+        let date2 = null
+        let year = null
+        let month = null
+        let day = null
+        let year2 = null
+        let month2 = null
+        let day2 = null
         // 判断当前日期输入框中是否选择了时间,并且开始日期和结束日期是否是同一天
-        if(this.startTime!=null){
-            date = this.startTime;
-            // 判断当前开始时间是标准时间还是字符串时间
-            
-           year = date.getFullYear(); // 年
-          month = date.getMonth() + 1; // 月
-          day = date.getDate(); // 日 
+        if (this.startTime != null) {
+          date = this.startTime
+          // 判断当前开始时间是标准时间还是字符串时间
+
+          year = date.getFullYear() // 年
+          month = date.getMonth() + 1 // 月
+          day = date.getDate() // 日
         }
-        if(this.endTime!=null){
-           date2 = this.endTime;
-           year2 = date2.getFullYear(); // 年
-          month2 = date2.getMonth() + 1; // 月
-          day2 = date2.getDate(); // 日 // 日
+        if (this.endTime != null) {
+          date2 = this.endTime
+          year2 = date2.getFullYear() // 年
+          month2 = date2.getMonth() + 1 // 月
+          day2 = date2.getDate() // 日 // 日
         }
-        if(this.startTime==null&&this.endTime==null){
+        if (this.startTime == null && this.endTime == null) {
           // 获取当前的日期时间
-          date = new Date();
-          year = date.getFullYear(); // 年
-          month = date.getMonth() + 1; // 月
-          day = date.getDate(); // 日
+          date = new Date()
+          year = date.getFullYear() // 年
+          month = date.getMonth() + 1 // 月
+          day = date.getDate() // 日
         }
         // 判断开始日期和结束日期是否是同一天
-        if(!(year==year2&&month==month2&&day==day2)&&(this.startTime!=null||this.endTime!=null)&&this.region==null){
+        if (
+          !(year == year2 && month == month2 && day == day2) &&
+          (this.startTime != null || this.endTime != null) &&
+          this.region == null
+        ) {
           // 当不是同一天的时候,直接弹窗警告
-          this.startTime = null;
-          this.endTime = null;
-          this.$message.warning("开始日期和结束日期不是同一天");
+          this.startTime = null
+          this.endTime = null
+          this.$message.warning('开始日期和结束日期不是同一天')
         }
         // 判断当前用户选择的具体班次
-        if(this.region == 0){
-          this.startTime = year+"-"+month+"-"+day+" "+"00:00:00";
+        if (this.region == 0) {
+          this.startTime = year + '-' + month + '-' + day + ' ' + '00:00:00'
           // 将结束时间加一
-          day =parseInt(day) + 1;
-          this.endTime = year+"-"+month+"-"+day+" "+"00:00:00";
-          
-        }else if(this.region == 1){
-          this.startTime = year+"-"+month+"-"+day+" "+"07:30:00";
-          this.endTime = year+"-"+month+"-"+day+" "+"15:30:00";
-        }else if(this.region == 2){
-          this.startTime = year+"-"+month+"-"+day+" "+"15:30:00";
-          this.endTime = year+"-"+month+"-"+day+" "+"23:30:00";
-        }else if(this.region == 3){
-          this.endTime = year+"-"+month+"-"+day+" "+"07:30:00";
+          day = parseInt(day) + 1
+          this.endTime = year + '-' + month + '-' + day + ' ' + '00:00:00'
+        } else if (this.region == 1) {
+          this.startTime = year + '-' + month + '-' + day + ' ' + '07:30:00'
+          this.endTime = year + '-' + month + '-' + day + ' ' + '15:30:00'
+        } else if (this.region == 2) {
+          this.startTime = year + '-' + month + '-' + day + ' ' + '15:30:00'
+          this.endTime = year + '-' + month + '-' + day + ' ' + '23:30:00'
+        } else if (this.region == 3) {
+          this.endTime = year + '-' + month + '-' + day + ' ' + '07:30:00'
           // 判断开始日期和结束日期是否跨月份了
-          if(month!=month2){
-            month = parseInt(month)-1
+          if (month != month2) {
+            month = parseInt(month) - 1
             // 获取前一个月份的最后一天
-            day = this.$options.methods.getdaysinmonth(year,month)
-          }else{
+            day = this.$options.methods.getdaysinmonth(year, month)
+          } else {
             // 将开始时间减一
-            day =parseInt(day)-1;
+            day = parseInt(day) - 1
           }
-          this.startTime = year+"-"+month+"-"+day+" "+"23:30:00";
+          this.startTime = year + '-' + month + '-' + day + ' ' + '23:30:00'
         }
         this.startTime = new Date(this.startTime)
         this.endTime = new Date(this.endTime)
-          console.log(this.startTime+"开始时间")
-          console.log(this.endTime+"结束时间")
+        console.log(this.startTime + '开始时间')
+        console.log(this.endTime + '结束时间')
         // 将拼接好的日期转换为时间戳
         startTime = Date.parse(this.startTime)
         endTime = Date.parse(this.endTime)
-        console.log(startTime+"开始时间2")
-        console.log(endTime+"结束时间2")
-      }else{
+        console.log(startTime + '开始时间2')
+        console.log(endTime + '结束时间2')
+      } else {
         if (this.startTime) {
-        startTime = sjTime(this.startTime);
+          startTime = sjTime(this.startTime)
         }
         if (this.endTime) {
-          endTime = sjTime(this.endTime);
+          endTime = sjTime(this.endTime)
         }
       }
-      
+
       // console.log(startTime)
       // console.log(endTime)
       if (startTime && endTime) {
         if (startTime < endTime) {
           // if(getCookie("orgCode") == "dagangadmin" || getCookie("orgCode") == "zidonghuabu"){
-          this.options.requestUrl = "/api/v1/wms/getWmsInboundResults?apiId=350&warehouseId="+2+"&startTime=" + startTime + "&endTime=" + endTime + "&i=" +new Date();
+          this.options.requestUrl =
+            '/api/v1/wms/getWmsInboundResults?apiId=450&warehouseId=' +
+            2 +
+            '&startTime=' +
+            startTime +
+            '&endTime=' +
+            endTime +
+            '&i=' +
+            new Date()
           // }else if(getCookie("orgCode") == "wuliuchuyunzhongxin"){
-          // this.options.requestUrl = "/api/v1/wms/getWmsInboundResults?apiId=371&orderType=13&startTime=" + startTime + "&endTime=" + endTime + "&i=" +new Date(); 
+          // this.options.requestUrl = "/api/v1/wms/getWmsInboundResults?apiId=371&orderType=13&startTime=" + startTime + "&endTime=" + endTime + "&i=" +new Date();
           // }else{
-          // this.options.requestUrl = '/api/v1/wms/getWmsInboundResults?apiId=371&userId=' + getCookie("orgCode") +"&startTime=" + startTime + "&endTime=" + endTime + "&i=" +new Date(); 
+          // this.options.requestUrl = '/api/v1/wms/getWmsInboundResults?apiId=371&userId=' + getCookie("orgCode") +"&startTime=" + startTime + "&endTime=" + endTime + "&i=" +new Date();
           // }
         } else {
-          this.startTime = null;
-          this.endTime = null;
-          this.$message.warning("开始时间要比结束时间早");
+          this.startTime = null
+          this.endTime = null
+          this.$message.warning('开始时间要比结束时间早')
         }
       } else {
         // this.getRequestUrl()
       }
     },
     selectionChange(selection) {
-      this.options.mapList = selection;
+      this.options.mapList = selection
     },
-    onreserved(){
-      console.log("fahaahahahaha")
+    onreserved() {
+      console.log('fahaahahahaha')
       if (this.options.mapList.length == 0) {
         this.$message({
-          type: "warning",
-          message: "请先选择入库单!",
-        });
+          type: 'warning',
+          message: '请先选择入库单!'
+        })
       } else {
-        this.$confirm("是否预留", "提示", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning",
-          center: true,
+        this.$confirm('是否预留', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning',
+          center: true
         })
           .then(() => {
             //初始化maplist
-            var mapList = [];
+            var mapList = []
             this.options.mapList.forEach((item, i) => {
               //初始化mapItem
               var mapItem = {
                 //入库实绩表id
                 inboundId: 0,
                 // 给一个标记定义其为入库变为预留
-                status: 0,
-              };
-              mapItem.inboundId = item.inboundId;
-              mapList.push(mapItem);
-            });
+                status: 0
+              }
+              mapItem.inboundId = item.inboundId
+              mapList.push(mapItem)
+            })
             this.$message({
-              type: "success",
-              message: "预留成功!",
-            });
+              type: 'success',
+              message: '预留成功!'
+            })
             console.log(mapList)
-            this.axios.post("/api/v1/wms/changeReserved", mapList).then((res) => {
-              console.log("res.data"+res.data)
+            this.axios.post('/api/v1/wms/changeReserved', mapList).then(res => {
+              console.log('res.data' + res.data)
               if (res.data >= 1) {
                 //改变查询条件
-                this.$refs.table.setDataRequestQuery({
-                  
-                });  
-                this.$router.go(0);
+                this.$refs.table.setDataRequestQuery({})
+                this.$router.go(0)
               }
-            });
-            console.log("fdagfaahh")
+            })
+            console.log('fdagfaahh')
           })
           .catch(() => {
             this.$message({
-              type: "info",
-              message: "取消上传!",
-            });
-          });
+              type: 'info',
+              message: '取消上传!'
+            })
+          })
       }
     }
   }
-
+}
 </script>
 
 <style lang="scss" scoped>
-.steel_inbound_real{
-    .sache{
-      display: flex;
-      justify-content: start;
-      align-items: center;
-      line-height: 40px;
-      height: 40px;
-      padding-left: 1.875rem;
-      .el-select {
+.steel_inbound_real {
+  .sache {
+    display: flex;
+    justify-content: start;
+    align-items: center;
+    line-height: 40px;
+    height: 40px;
+    padding-left: 1.875rem;
+    .el-select {
       width: 100%;
       .el-input__inner {
         width: 150px;
       }
     }
-    }
   }
-</style>
+}
+</style>

+ 1 - 1
src/views/index/components/login.vue

@@ -2,7 +2,7 @@
   <div class="icore-lg">
     <img
       style="width: 100%; height: 100%; position: absolute"
-      src="../../../assets/img/Coverstdil.png"
+      src="../../../assets/img/icore-shown-all.png"
     />
     <section v-if="isJump === true">
       <div class="jumpText">正在为您跳转,请稍后...</div>

+ 0 - 7
src/views/index/components/printScan1.vue

@@ -67,13 +67,6 @@ export default {
     }
   },
   created() {
-    try {
-      var objShell = new ActiveXObject('WScript.Shell')
-      iReturnCode = objShell.Run('cmd.exe /c ipconfig', 0, true)
-    } catch (e) {
-      alert(iRetrunCode)
-      console.dir(e)
-    }
     localStorage.setItem(
       'onlyKey',
       Math.floor(Math.random() * 60 * 24 * 60) + 'huabao'

+ 25 - 2
src/views/inward/components/offsetSteel/saleSteelTruckOrder/platformStockInfo.vue

@@ -495,7 +495,8 @@ export default {
       operateName: '编辑',
       unloadPointList: [],
       spanArr: [],
-      mergeList: ['wagonNo', 'wagonBillWeight', 'OutStation','materialWeight'],
+      spanArr1: [],
+      mergeList: ['wagonNo', 'wagonBillWeight', 'OutStation'],
       filterMap: {},
       filterConsigneeList: [],
       filterEnStationList: [],
@@ -863,26 +864,41 @@ export default {
     getSpanArr(data) {
       //每次调用方法初始化
       this.spanArr = []
+      this.spanArr1 = []
       for (var i = 0; i < data.length; i++) {
         if (i === 0) {
           this.spanArr.push(1)
           data[i].group = i
           this.pos = 0
+          this.spanArr1.push(1)
+          this.pos1 = 0
         } else {
           // 判断当前元素与上一个元素是否相同
           if (
             data[i].orderId === data[i - 1].orderId &&
             data[i].wagonNo === data[i - 1].wagonNo &&
             data[i].OutStation === data[i - 1].OutStation
-            || ( data[i].weightBatchId && data[i].weightBatchId ===data[i - 1].weightBatchId)
           ) {
             this.spanArr[this.pos] += 1
             data[i].group = data[i - 1].group
             this.spanArr.push(0)
+
+            if(data[i].weightBatchId && data[i].weightBatchId ===data[i - 1].weightBatchId){
+              //批次合并
+              this.spanArr1[this.pos1] += 1
+              this.spanArr1.push(0)
+            }else{
+              this.spanArr1.push(1)
+              this.pos1 = i
+            }
+
           } else {
             this.spanArr.push(1)
             this.pos = i
             data[i].group = data[i - 1].group + 1
+
+            this.spanArr1.push(1)
+            this.pos1 = i
           }
         }
       }
@@ -895,6 +911,13 @@ export default {
           rowspan: _row,
           colspan: _col
         }
+      }else if('materialWeight' == column.property){
+        const _row = this.spanArr1[rowIndex]
+        const _col = _row > 0 ? 1 : 0
+        return {
+          rowspan: _row,
+          colspan: _col
+        }
       }
     },
     //导出Excel

+ 22 - 23
src/views/sale/components/transportFreight/saleTruckSettlement/bmsTruckDetailsOrderNew.vue

@@ -1379,20 +1379,14 @@ export default {
       //筛选条件1(客户)
       filters1: [],
       spanArr: [],
-      spanArr1:[],
-      spanArr2:[],
-      spanArr3:[],
+      spanArr1: [],
+      spanArr2: [],
+      spanArr3: [],
       pos: 0,
-      pos1:0,
-      pos2:0,
-      pos3:0,
-      mergeListBatch : [
-        '净重',
-        '皮重时间',
-        '皮重',
-        '毛重时间',
-        '毛重',
-      ],
+      pos1: 0,
+      pos2: 0,
+      pos3: 0,
+      mergeListBatch: ['磅重', '运费'],
       //需要合并列的名称
       mergeList: [
         // '选择',
@@ -1424,7 +1418,7 @@ export default {
         '抵达时间',
         '签收时间',
         '最终运价',
-        '摘要',
+        '摘要'
       ],
       //需要合并列的名称(已结算)
       mergeList1: [
@@ -1456,7 +1450,7 @@ export default {
         '销售片区',
         '抵达时间',
         '签收时间',
-        '最终运价',
+        '最终运价'
       ],
 
       tableTitle: '销售钢材统计报表',
@@ -3351,12 +3345,14 @@ export default {
           if (data[i].saleOrderMaterialId === data[i - 1].saleOrderMaterialId) {
             this.spanArr[this.pos] += 1
             this.spanArr.push(0)
-
-            if(data[i].weightBatchId && data[i].weightBatchId ===data[i - 1].weightBatchId){
+            if (
+              data[i].weightBatchId &&
+              data[i].weightBatchId === data[i - 1].weightBatchId
+            ) {
               //批次合并
               this.spanArr2[this.pos2] += 1
               this.spanArr2.push(0)
-            }else{
+            } else {
               this.spanArr2.push(1)
               this.pos2 = i
             }
@@ -3387,11 +3383,14 @@ export default {
             this.spanArr1[this.pos] += 1
             this.spanArr1.push(0)
 
-            if(data[i].weightBatchId && data[i].weightBatchId ===data[i - 1].weightBatchId){
+            if (
+              data[i].weightBatchId &&
+              data[i].weightBatchId === data[i - 1].weightBatchId
+            ) {
               //批次合并
               this.spanArr3[this.pos3] += 1
               this.spanArr3.push(0)
-            }else{
+            } else {
               this.spanArr3.push(1)
               this.pos3 = i
             }
@@ -3400,7 +3399,7 @@ export default {
             this.pos = i
 
             this.spanArr3.push(1)
-              this.pos3 = i
+            this.pos3 = i
           }
         }
       }
@@ -3413,7 +3412,7 @@ export default {
           rowspan: _row,
           colspan: _col
         }
-      }else if(this.mergeListBatch.indexOf(column.label) != -1){
+      } else if (this.mergeListBatch.indexOf(column.label) != -1) {
         const _row = this.spanArr2[rowIndex]
         const _col = _row > 0 ? 1 : 0
         return {
@@ -3430,7 +3429,7 @@ export default {
           rowspan: _row,
           colspan: _col
         }
-      }else if(this.mergeListBatch.indexOf(column.label) != -1){
+      } else if (this.mergeListBatch.indexOf(column.label) != -1) {
         const _row = this.spanArr2[rowIndex]
         const _col = _row > 0 ? 1 : 0
         return {

+ 59 - 39
src/views/statisticalReport/components/salesLogisticsStatistics/saleSteelReports.vue

@@ -1653,6 +1653,7 @@
             :data="steelMap.mapList"
             border
             style="width: 100%; margin-top: 20px"
+            :span-method="objectSpanMethod2"
           >
             <el-table-column
               prop="materialName"
@@ -1756,7 +1757,7 @@
               width="100px"
             >
             </el-table-column>
-            <el-table-column fixed="right" label="操作" width="200">
+            <el-table-column fixed="right" label="异常操作" width="200">
               <template slot-scope="scope">
                 <el-button
                   @click.native.prevent="
@@ -2038,7 +2039,14 @@ export default {
       spanArr1: [],
       spanArr2: [],
       spanArr3: [],
-      mergeListBatch: ['净重', '皮重时间', '皮重', '毛重时间', '毛重'],
+      mergeListBatch: [
+        '净重',
+        '皮重时间',
+        '皮重',
+        '毛重时间',
+        '毛重',
+        '异常操作'
+      ],
       pos2: 0,
       pos3: 0,
       pos1: 0,
@@ -2084,12 +2092,7 @@ export default {
         '拼数',
         '是否继续装',
         '订单上传时间',
-        '收款公司',
-        '净重',
-        '皮重时间',
-        '皮重',
-        '毛重时间',
-        '毛重'
+        '收款公司'
       ],
       //钢材多拼车辆线路ID
       //索引从1-10为1-10拼路线ID
@@ -2904,7 +2907,8 @@ export default {
     },
     //删除计量实绩
     linkageDeleteTransportOrder(row, steelMap) {
-      console.log(row)
+      console.log(row, 'row')
+      debugger
       if (row.netWeight != null && row.netWeight != '') {
         //如果净重不为空
         let arr = []
@@ -2913,7 +2917,9 @@ export default {
           good: row.materialName,
           goodspa: `${row.materialSpecification}(${row.materialModel})`,
           resultCrossWeightTime: row.grossWeightTime,
-          saleMaterialId: row.saleMaterialId
+          saleMaterialId: row.saleMaterialId,
+          weightBatchId: row.weightBatchId,
+          userName: getCookie('loginName')
         }
         arr.push(map)
         this.axios
@@ -3260,6 +3266,7 @@ export default {
           .then(res => {
             this.steelMap = res.data.data
             this.exceptionHandleVisible = true
+            this.getSpanArr1(this.steelMap.mapList)
           })
       } else {
         this.$message({
@@ -4344,25 +4351,13 @@ export default {
           .post('/api/v1/ams/updateCapacityNumberInFactory', this.steelMap)
           .then(res => {
             if (res.data.code == 200) {
-              this.$message.success('变更车牌号成功!')
+              this.$message({
+                type: 'success',
+                message: '变更车号成功,请通知驾驶员',
+                duration: 2500,
+                offset: '250'
+              })
               this.operation(this.steelMap)
-              console.log('更改车牌号之后的变化')
-              // console.log(res.data)
-              // if (res.data.data.capacityTel != 0) {
-              //   console.log('进入了这个界面')
-              //   this.steelMap.capacityTel = res.data.data.capacityTel
-              // } else {
-              //   this.axios
-              //     .post(
-              //       '/api/v1/ams/matchingDriverTelRecently?capacityNumber=' +
-              //         this.steelMap.capacityNo
-              //     )
-              //     .then(res => {
-              //       if (res.data.data != null) {
-              //         this.steelMap.capacityTel = res.data.data
-              //       }
-              //     })
-              // }
               this.onclick(this.filterMap)
               loading.close()
             } else {
@@ -4877,25 +4872,38 @@ export default {
     getSpanArr(data) {
       //每次调用方法初始化
       this.spanArr = []
+      this.spanArr2 = []
       for (var i = 0; i < data.length; i++) {
         if (i === 0) {
           this.spanArr.push(1)
+          this.spanArr2.push(1)
           // data[i].group = i
           this.pos = 0
+          this.pos2 = 0
         } else {
           // 判断当前元素与上一个元素是否相同
-          if (
-            data[i].saleOrderMaterialId === data[i - 1].saleOrderMaterialId ||
-            (data[i].weightBatchId &&
-              data[i].weightBatchId === data[i - 1].weightBatchId)
-          ) {
+          if (data[i].saleOrderMaterialId === data[i - 1].saleOrderMaterialId) {
             this.spanArr[this.pos] += 1
             // data[i].group = data[i - 1].group
             this.spanArr.push(0)
+
+            if (
+              data[i].weightBatchId &&
+              data[i].weightBatchId === data[i - 1].weightBatchId
+            ) {
+              //批次合并
+              this.spanArr2[this.pos2] += 1
+              this.spanArr2.push(0)
+            } else {
+              this.spanArr2.push(1)
+              this.pos2 = i
+            }
           } else {
             this.spanArr.push(1)
             this.pos = i
             // data[i].group = data[i - 1].group + 1
+            this.spanArr2.push(1)
+            this.pos2 = i
           }
         }
       }
@@ -4913,15 +4921,10 @@ export default {
           this.pos3 = 0
         } else {
           // 判断当前元素与上一个元素是否相同
-          if (
-            data[i].saleOrderMaterialId === data[i - 1].saleOrderMaterialId ||
-            (data[i].weightBatchId &&
-              data[i].weightBatchId === data[i - 1].weightBatchId)
-          ) {
+          if (data[i].saleOrderMaterialId === data[i - 1].saleOrderMaterialId) {
             this.spanArr1[this.pos] += 1
             // data[i].group = data[i - 1].group
             this.spanArr1.push(0)
-
             if (
               data[i].weightBatchId &&
               data[i].weightBatchId === data[i - 1].weightBatchId
@@ -4977,6 +4980,23 @@ export default {
         }
       }
     },
+    objectSpanMethod2({ row, column, rowIndex, columnIndex }) {
+      if (this.mergeList.indexOf(column.label) != -1) {
+        const _row = this.spanArr1[rowIndex]
+        const _col = _row > 0 ? 1 : 0
+        return {
+          rowspan: _row,
+          colspan: _col
+        }
+      } else if (this.mergeListBatch.indexOf(column.label) != -1) {
+        const _row = this.spanArr3[rowIndex]
+        const _col = _row > 0 ? 1 : 0
+        return {
+          rowspan: _row,
+          colspan: _col
+        }
+      }
+    },
     //计算总件数和总车数
     // getTotalNum(data) {
     //   //通过车序号的个数来计算车数

+ 4 - 2
src/views/statisticalReport/router/index.js

@@ -47,8 +47,9 @@ const purchaseMineral = () => import('../components/purachaseMineral.vue')
 const inwardSporadicReport = () =>
   import('../components/sporadicReport/inwardSporadicReport.vue')
 const getInstall = () => import('../components/inwardReport/getInstall.vue')
+/** 
 const getCapacityByDefend = () =>
-  import('../components/defendCapacity/getCapacityByDefend.vue')
+  import('../components/defendCapacity/getCapacityByDefend.vue')*/
 const inwardAssemble = () =>
   import('../components/inwardAssemble/inwardAssemble.vue')
 const loadCapacityDetail = () =>
@@ -231,12 +232,13 @@ const constantRouterMap = [
         meta: { code: 'xtpzgl-yhgl' },
         component: getInstall
       },
+      /** 
       {
         path: 'getCapacityByDefend',
         name: 'getCapacityByDefend',
         meta: { code: 'xtpzgl-yhgl' },
         component: getCapacityByDefend
-      },
+      },*/
       {
         path: 'inwardAssemble',
         name: 'inwardAssemble',