zx 2 年之前
父节点
当前提交
1f91ae418c

+ 1 - 0
build/utils.js

@@ -17,6 +17,7 @@ const devPathSrc = path.resolve(__dirname, "../../../src"); // node_modules应
 //  'statisticalReport','systemConfig','TMS','WMS','workFlow']
 // let devModules = ["index", "appoint", "statisticalReport"];
 let devModules = ["all"];
+
 // let devModules = ['index','appoint','sale','statisticalReport','RMS','TMS','WMS']
 // let devModules = ["index", "ADMINISTRATORS", "RMS"];
 // let devModules = ["index", "inward", "statisticalReport"];

+ 89 - 10
src/views/TMS/components/domesticMine/wagonLoadAdd.vue

@@ -1,9 +1,8 @@
 <template>
-  <!-- 添加车皮装车实绩 -->
+  <!-- 国产矿导入-->
   <div class="addWagonLoad">
     <page-title>返回</page-title>
     <div class="cp">
-      <span >车皮号:</span>
       <el-upload style="margin: 8px;"
           class="upload-excel"
           action=""
@@ -11,15 +10,21 @@
           :show-file-list="false"
           accept=".csv, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
           :auto-upload="false">
-          <el-button  type="primary">导入</el-button>
+          <el-button  type="primary">导入车皮号(Excel)</el-button>
       </el-upload>
-      <span >当前导入数量:{{tableData.length}}</span>
+      <div style="margin-right:200px;">当前导入数量:{{tableData.length}}</div>
+       <!-- <el-button type="primary" @click="exportData()"
+        ><i class="el-icon-download"></i>下载导入模板</el-button> -->
+    </div>
+    <div>
+      <span style="color:red">导入数据中的 品名、发货单位、车号、发站 是必须的</span>
     </div>
     <div class="table item">
       <el-table
         stripe
         :data="tableData"
-        style="width: 100%">
+        style="width: 100%"
+        id="domesticTable">
         <el-table-column
         type="index"
         width="50"
@@ -216,6 +221,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime, isNumber } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -523,10 +529,14 @@ export default {
         row.resultLoadingDate=sjTime(that.form1.resultLoadingDate);//装车日期
         row.resultRemarks=that.form1.resultRemarks;//备注
       })
-      console.log(that.tableData);
+      let data={
+        list:this.tableData,
+        userId:getCookie("userId")
+      }
+      console.log(data);
       //请求添加
       this.axios
-        .post("/api/v1/tms/addDomesticLoadResult", that.tableData)
+        .post("/api/v1/tms/addDomesticLoadResult", data)
         .then((res) => {
           console.log(res);
           if (res.data.code == "200") {
@@ -570,9 +580,30 @@ export default {
           if(rows.length>0){
             that.disable=false;
             that.tableData=[];
-            if((typeof rows[0]['车号'])=='undefined' || (typeof rows[0]['发站'])=='undefined' ){
-              that.$message({
-                message: "导入Excel格式错误,请参考下方表头格式!",
+            if((typeof rows[0]['车号'])=='undefined'){
+               that.$message({
+                message: "导入Excel格式错误,车号不能为空!",
+                type: "warning",
+              });
+              return;
+            }
+            if((typeof rows[0]['品  名'])=='undefined' && (typeof rows[0]['品名'])=='undefined' && (typeof rows[0]['物资'])=='undefined'){
+               that.$message({
+                message: "导入Excel格式错误,品名不能为空!",
+                type: "warning",
+              });
+              return;
+            }
+            if((typeof rows[0]['发货单位'])=='undefined'){
+               that.$message({
+                message: "导入Excel格式错误,发货单位不能为空!",
+                type: "warning",
+              });
+              return;
+            }
+            if((typeof rows[0]['发站']) =='undefined'){
+               that.$message({
+                message: "导入Excel格式错误,发站不能为空!",
                 type: "warning",
               });
               return;
@@ -599,6 +630,35 @@ export default {
               if(typeof temp.materialName=='undefined' || temp.materialName==null){
                 temp.materialName=row['物资'];
               }
+              //判断校验
+              if((typeof temp.wagonNo)=='undefined'){
+                that.$message({
+                  message: "车号不能为空!导入Excel停止!",
+                  type: "warning",
+                });
+                return;
+              }
+              if((typeof temp.materialName)=='undefined'){
+                that.$message({
+                  message: "品名不能为空!导入Excel停止!",
+                  type: "warning",
+                });
+                return;
+              }
+              if((typeof temp.supplierName)=='undefined'){
+                that.$message({
+                  message: "发货单位不能为空!导入Excel停止!",
+                  type: "warning",
+                });
+                return;
+              }
+              if((typeof temp.sendStation)=='undefined'){
+                that.$message({
+                  message: "发站不能为空!导入Excel停止!",
+                  type: "warning",
+                });
+                return;
+              }
               that.tableData.push(temp);
             }
             else{
@@ -607,6 +667,25 @@ export default {
         });
         };
         reader.readAsBinaryString(file.raw); //以二进制方式读取
+    },
+    //导出模板
+    exportData(){
+      let tables = document.getElementById("domesticTable");
+      let table_book = XLSX.utils.table_to_book(tables);
+      var table_write = XLSX.utils.write(table_book, {
+        bookType: "xlsx",
+        bookSST: true,
+        type: "array",
+      });
+      try {
+        this.$FileSaver.saveAs(
+          new Blob([table_write], { type: "application/octet-stream" }),
+          ".xlsx"
+        );
+      } catch (e) {
+        if (typeof console !== "undefined") console.log(e, table_write);
+      }
+      return table_write;
     }
   },
 };

+ 2 - 0
src/views/TMS/components/domesticMine/wagonLoadEdit.vue

@@ -51,6 +51,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
  data(){
@@ -168,6 +169,7 @@ export default {
         arrivalStationId: this.toTheStationId,
         resultLoadingDate: sjTime(this.form1.resultLoadingDate),
         resultRemarks: this.form1.resultRemarks,
+        userId:getCookie("userId"),
         resultType:3
       };
       console.log(tmstrainLoadingResult)

+ 4 - 1
src/views/TMS/components/domesticMine/wagonLoadbu.vue

@@ -116,6 +116,7 @@
 
 <script>
 import PageTitle from "@/components/Page/Title";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -202,8 +203,10 @@ export default {
       else{
         let map = {
           resultIdList:this.selecTionListMap,
-          purchaseOrderId:this.purchaseOrderId
+          purchaseOrderId:this.purchaseOrderId,
+          userId:getCookie("userId")
         }
+        console.log(map);
         let that=this;
         this.axios.post('/api/v1/tms/updateDomesticLoadResult',map).then((res)=>{
           console.log(res.data.data)

+ 1 - 0
src/views/TMS/components/domesticMine/wagonUnLoadAdd.vue

@@ -173,6 +173,7 @@ export default {
         resultUnloadTime: sjTime(this.form1.resultUnloadTime),
         resultRemark: this.form1.resultRemark,
         unloadingPointId:this.unloadPointId,
+        insertUsername:getCookie("userId"),
         resultType: 3,
       };
       console.log(tmstrainWagonUnloadResult);

+ 3 - 1
src/views/TMS/components/domesticMine/wagonUnLoadEdit.vue

@@ -16,6 +16,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -62,6 +63,7 @@ export default {
         unloadingPointId: this.form1.unloadingPointId,
         resultBigTicketWeight: this.form1.resultBigTicketWeight,
         resultRailHorizontalWeight: this.form1.resultRailHorizontalWeight,
+        updateUsername:getCookie("userId"),
         resultRemark: this.form1.resultRemark,
       };
       console.log(tmstrainWagonUnloadResult);
@@ -77,7 +79,7 @@ export default {
             "/api/v1/tms/upadteTmstrainWagonUnLoadResultByUnLoadingId",
             tmstrainWagonUnloadResult
           )
-          .then(() => {
+          .then((res) => {
             if (res.data.code == "200") {
               this.$message({
                 type: "success",

+ 3 - 1
src/views/TMS/components/importedEmergency/addWagonLoadEmergency.vue

@@ -1,5 +1,5 @@
 <template>
-  <!-- 添加车皮装车实绩 -->
+  <!-- 海港-老区轨道衡新增装车  -->
   <div class="addWagonLoad">
     <page-title>返回</page-title>
     <div class="purchaseOrder_table">
@@ -242,6 +242,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -596,6 +597,7 @@ export default {
           arrivalStationId: this.toTheStationId,
           resultLoadingDate: sjTime(this.form1.resultLoadingDate),
           resultRemarks: this.form1.resultRemarks,
+          userId:getCookie("userId"),
           resultType:2,
         }
         console.log(map);

+ 2 - 0
src/views/TMS/components/importedEmergency/addWagonUnLoadEmergency.vue

@@ -91,6 +91,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime,isNumber } from "@/utils/sharedJsFile";
+import { getCookie } from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -169,6 +170,7 @@ export default {
         resultUnloadTime: sjTime(this.form1.resultUnloadTime),
         resultRemark: this.form1.resultRemark,
         unloadingPointId:this.unloadPointId,
+        insertUsername:getCookie("userId"),
         resultType: 2,
       };
       console.log(tmstrainWagonUnloadResult);

+ 17 - 9
src/views/TMS/components/importedEmergency/editWagonLoadEmergency.vue

@@ -52,6 +52,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -179,12 +180,12 @@ export default {
         resultLoadingDate: sjTime(this.form1.resultLoadingDate),
         batchId: this.form1.batchId,
         capacityId: this.form1.capacityId,
-        resultMaterialNumber: this.form1.resultMaterialNumber,
-        resultMaterialTheoryweight: this.form1.resultMaterialTheoryweight,
         resultRemarks: this.form1.resultRemarks,
+        purchaseOrderNo:this.form1.purchaseOrderNo,
+        userId:getCookie("userId"),
         resultType:2
       };
-      console.log(tmstrainLoadingResult)
+      console.log(tmstrainLoadingResult);
       if (
         tmstrainLoadingResult.resultWagonNo == null ||
         tmstrainLoadingResult.sendStationId == null ||
@@ -199,12 +200,19 @@ export default {
             "/api/v1/tms/upadteTmstrainLoadingResultByResultId",
             tmstrainLoadingResult
           )
-          .then(() => {
-            this.$message({
-              type: "success",
-              message: "修改成功!",
-            });
-            this.$router.go(-1);
+          .then((res) => {
+            if (res.data.code == "200") {
+              this.$message({
+                type: "success",
+                message: "修改成功!",
+              });
+              this.$router.go(-1);
+            }else{
+               this.$message({
+                type: "error",
+                message: res.data.data,
+              });
+            }
           });
     },
   },

+ 3 - 1
src/views/TMS/components/importedEmergency/editWagonUnLoadEmergency.vue

@@ -17,6 +17,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime,isNumber } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
  data(){
@@ -59,6 +60,7 @@ export default {
         unloadingPointId: this.form1.unloadingPointId,
         resultBigTicketWeight: this.form1.resultBigTicketWeight,
         resultRailHorizontalWeight: this.form1.resultRailHorizontalWeight,
+        updateUsername:getCookie("userId"),
         resultRemark: this.form1.resultRemark
       };
       if (tmstrainWagonUnloadResult.resultWagonNo==null
@@ -70,7 +72,7 @@ export default {
           "/api/v1/tms/upadteTmstrainWagonUnLoadResultByUnLoadingId",
           tmstrainWagonUnloadResult
         )
-       .then(() => {
+       .then((res) => {
           this.$message({
             type: "success",  
             message: "修改成功!",

+ 3 - 1
src/views/TMS/components/importedMine/addWagonLoad.vue

@@ -1,5 +1,5 @@
 <template>
-  <!-- 添加车皮装车实绩 -->
+  <!-- 万州港-达州新增装车 -->
   <div class="addWagonLoad">
     <page-title>返回</page-title>
     <div class="purchaseOrder_table">
@@ -242,6 +242,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -596,6 +597,7 @@ export default {
           arrivalStationId: this.toTheStationId,
           resultLoadingDate: sjTime(this.form1.resultLoadingDate),
           resultRemarks: this.form1.resultRemarks,
+          userId:getCookie("userId"),
           resultType:1,
         }
         console.log(map);

+ 2 - 0
src/views/TMS/components/importedMine/addWagonUnLoad.vue

@@ -94,6 +94,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime,isNumber } from "@/utils/sharedJsFile";
+import { getCookie } from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -171,6 +172,7 @@ export default {
         resultUnloadTime: sjTime(this.form1.resultUnloadTime),
         resultRemark: this.form1.resultRemark,
         unloadingPointId:this.unloadPointId,
+        insertUsername:getCookie("userId"),
         resultType: 1,
       };
       console.log(tmstrainWagonUnloadResult);

+ 6 - 2
src/views/TMS/components/importedMine/editWagonLoad.vue

@@ -53,6 +53,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime, isNumber } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -176,11 +177,13 @@ export default {
         resultLoadingDate: sjTime(this.form1.resultLoadingDate),
         batchId: this.form1.batchId,
         capacityId: this.form1.capacityId,
-        resultMaterialNumber: this.form1.resultMaterialNumber,
         resultMaterialTheoryweight: this.form1.resultMaterialTheoryweight,
         resultRemarks: this.form1.resultRemarks,
+        purchaseOrderNo:this.form1.purchaseOrderNo,
+        userId:getCookie("userId"),
         resultType:1
       };
+      console.log(tmstrainLoadingResult);
       if (
         tmstrainLoadingResult.resultId ==null ||
         tmstrainLoadingResult.resultIsclear == null ||
@@ -202,6 +205,7 @@ export default {
                 type: "success",
                 message: "修改成功!",
               });
+                this.$router.go(-1);
             }else{
                this.$message({
                 type: "error",
@@ -209,7 +213,7 @@ export default {
               });
             }
 
-            this.$router.go(-1);
+          
           });
     },
   },

+ 2 - 0
src/views/TMS/components/importedMine/editWagonUnLoad.vue

@@ -18,6 +18,7 @@
 <script>
 import PageTitle from "@/components/Page/Title";
 import { sjTime } from "@/utils/sharedJsFile";
+import {getCookie} from "@/utils/util.js";
 export default {
   components: { PageTitle },
   data() {
@@ -63,6 +64,7 @@ export default {
         resultArrivalDate: sjTime(this.form1.resultArrivalDate),
         resultUnloadTime: sjTime(this.form1.resultUnloadTime),
         unloadingPointId: this.form1.unloadingPointId,
+        updateUsername:getCookie("userId"),
         resultRemark: this.form1.resultRemark,
       };
       console.log(tmstrainWagonUnloadResult);

+ 95 - 19
src/views/appoint/components/saleContract/addSaleOrder.vue

@@ -241,6 +241,9 @@
 
     <!-- 新增物资和生成一车 -->
     <div class="button-box">
+      <el-button type="primary" class="btn" @click="singleDistribute"
+        >单拼分配到每车</el-button
+      >
       <el-button type="primary" class="btn" @click="createACar"
         >添加到订单</el-button
       >
@@ -1216,20 +1219,104 @@ export default {
       //调用记录每一行的合并数的方法
       this.getSpanArr(this.selectionList);
     },
-    //准备生成部分订单
-    createACar() {
+    singleDistribute() {
+      let ml = this.materialList.length;
+      if (ml == 0) {
+        this.$message.warning("请至少填入一车物资");
+        return;
+      }
+      let singleArr = this.materialList;
+      this.$confirm(
+        `以上${ml}车物资将分配到不同的${ml}车,确定继续分配?`,
+        "提醒",
+        {
+          cancelButtonText: "取消",
+          confirmButtonText: "确定",
+          center: true
+        }
+      ).then(() => {
+        this.creatArtSingle(singleArr);
+      });
+    },
+    async creatArtSingle(singleArr) {
       let i = 0;
-      this.materialList.forEach(e => {
-        if (!/(^[1-9]\d*$)/.test(e.meterNumber) && e.meterNumber != null) {
-          e.meterNumber = null;
+      singleArr.forEach(e => {
+        if (!/(^[1-9]\d*$)/.test(e.orderPlanWeight)) {
+          e.orderPlanWeight = null;
           i++;
         }
       });
       if (i != 0) {
-        i = 0;
-        this.$message.error("米数请输入正整数");
+        this.$message.error("件数必填且请输入正整数");
+        return;
+      }
+      singleArr.forEach(e => {
+        if (e.materialName.includes("定尺")) {
+          if (!e.meterNumber) {
+            i++;
+          }
+        }
+      });
+      if (i != 0) {
+        this.$message.error("定尺必须填写米数");
         return;
       }
+      if (
+        !this.saleOrderConsigneeTel &&
+        this.ignoreSaleOrderConsigneeTel == 0
+      ) {
+        this.$confirm(
+          "收货客户电话未填写会导致无法接收车辆发货短信, 是否继续?",
+          "提示",
+          {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }
+        )
+          .then(() => {
+            this.ignoreSaleOrderConsigneeTel = 1;
+            this.addMaterialToSaleOrderSingle();
+          })
+          .catch(() => {
+            this.$message.info("已取消!");
+          });
+      } else {
+        this.addMaterialToSaleOrderSingle();
+      }
+    },
+    addMaterialToSaleOrderSingle() {
+      this.materialList.forEach(e => {
+        var addmap = {
+          cxh: this.maxCxh,
+          materialName: e.materialName,
+          Specification: e.Specification,
+          materialCode: e.materialCode,
+          orderPlanWeight: e.orderPlanWeight,
+          meterNumber: e.meterNumber,
+          isPound: e.isPound,
+          saleShipperAddressId: this.saleShipperAddressId,
+          place: this.place1,
+          saleShipperAddressName: this.saleShipperAddressName,
+          saleDateOfReceipt: this.saleDateOfReceipt,
+          saleOrderConsigneeTel: this.saleOrderConsigneeTel,
+          truckRemark: this.truckRemark,
+          materialId: e.materialId,
+          haveMeter: e.haveMeter,
+          isDisable: e.isDisable
+        };
+        console.log(addmap);
+        this.selectionList.push(addmap);
+        //最大车序号加1
+        this.maxCxh += 1;
+        this.onblur();
+      });
+      this.materialList = [];
+      this.getSpanArr(this.selectionList);
+    },
+    //准备生成部分订单
+    createACar() {
+      let i = 0;
       this.materialList.forEach(e => {
         if (!/(^[1-9]\d*$)/.test(e.orderPlanWeight)) {
           e.orderPlanWeight = null;
@@ -1340,8 +1427,8 @@ export default {
             haveMeter: e.haveMeter,
             isDisable: e.isDisable
           };
+          console.log(addmap);
           this.selectionList.push(addmap);
-          console.log(this.selectionList);
         });
         //清空materialList
         this.materialList = [];
@@ -1636,17 +1723,6 @@ export default {
         return;
       }
       let i = 0;
-      this.selectionList.forEach(e => {
-        if (!/(^[1-9]\d*$)/.test(e.meterNumber) && e.meterNumber != null) {
-          e.meterNumber = null;
-          i++;
-        }
-      });
-      if (i != 0) {
-        i = 0;
-        this.$message.error("米数请输入正整数");
-        return;
-      }
       this.selectionList.forEach(e => {
         if (!/(^[1-9]\d*$)/.test(e.orderPlanWeight)) {
           e.orderPlanWeight = null;

+ 0 - 33
src/views/appoint/components/saleContract/editSaleOrder.vue

@@ -1245,17 +1245,6 @@ export default {
     createACar() {
       this.onblur();
       let i = 0;
-      this.materialList.forEach(e => {
-        if (!/(^[1-9]\d*$)/.test(e.meterNumber) && e.meterNumber != null) {
-          e.meterNumber = null;
-          i++;
-        }
-      });
-      if (i != 0) {
-        i = 0;
-        this.$message.error("米数请输入正整数");
-        return;
-      }
       this.materialList.forEach(e => {
         if (!/(^[1-9]\d*$)/.test(e.orderPlanWeight)) {
           e.orderPlanWeight = null;
@@ -1388,17 +1377,6 @@ export default {
     addMaterialToCxh(toCxh) {
       this.onblur();
       let i = 0;
-      this.materialList.forEach(e => {
-        if (!/(^[1-9]\d*$)/.test(e.meterNumber) && e.meterNumber != null) {
-          e.meterNumber = null;
-          i++;
-        }
-      });
-      if (i != 0) {
-        i = 0;
-        this.$message.error("米数请输入正整数");
-        return;
-      }
       this.materialList.forEach(e => {
         if (!/(^[1-9]\d*$)/.test(e.orderPlanWeight)) {
           e.orderPlanWeight = null;
@@ -1773,17 +1751,6 @@ export default {
         return;
       }
       let i = 0;
-      this.selectionList.forEach(e => {
-        if (!/(^[1-9]\d*$)/.test(e.meterNumber) && e.meterNumber != null) {
-          e.meterNumber = null;
-          i++;
-        }
-      });
-      if (i != 0) {
-        i = 0;
-        this.$message.error("米数请输入正整数");
-        return;
-      }
       this.selectionList.forEach(e => {
         if (!/(^[1-9]\d*$)/.test(e.orderPlanWeight)) {
           e.orderPlanWeight = null;

+ 7 - 4
src/views/appoint/components/saleContract/updateSaleOrderSteel.vue

@@ -563,7 +563,6 @@ export default {
   mounted() {
     console.log(this.$route);
     console.log(this.$route.params.deleted);
-
     this.getOrderList();
     this.getAllProvince();
   },
@@ -575,6 +574,9 @@ export default {
     //车辆变更
     updateCapacity(scope) {
       this.oldCapacityNum = scope.row.capacityNumber;
+      this.saleOrderMaterialId = scope.row.saleOrderMaterialId;
+      this.lineSequence = scope.row.lineSequence;
+      this.orderId = scope.row.orderId;
       this.$confirm("确定变更车辆吗?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
@@ -611,6 +613,7 @@ export default {
           .then(res => {
             if (res.data.code == 200) {
               this.$message.success("变更成功");
+              this.getOrderList();
               this.capacityDialog = false;
             } else {
               this.$message.success("变更失败,请联系管理员");
@@ -1164,9 +1167,9 @@ export default {
           console.log(res.data.data);
           this.tableData = [];
           this.tableData = res.data.data;
-          this.orderId = this.tableData[0].orderId;
-          this.lineSequence = this.tableData[0].lineSequence;
-          this.saleOrderMaterialId = this.tableData[0].saleOrderMaterialId;
+          // this.orderId = this.tableData[0].orderId;
+          // this.lineSequence = this.tableData[0].lineSequence;
+          // this.saleOrderMaterialId = this.tableData[0].saleOrderMaterialId;
           this.getSpanArr(this.tableData);
         });
     },

+ 6 - 0
src/views/queue/components/qmsEnFacotory/queueFStart.vue

@@ -258,12 +258,18 @@ export default {
   watch: {
     activeName() {}
   },
+  created() {
+    this.myWebsocket();
+  },
   mounted() {
     this.infomation();
     this.getSpellingArray();
     this.getNoSpellingArray();
   },
   methods: {
+    myWebsocket() {
+      let wss = new WebSocket("wss:wl.dasteel.cn:32322/websocket/socketServer");
+    },
     refresh() {
       this.getSpellingArray();
       this.getNoSpellingArray();

+ 28 - 49
src/views/sale/components/transport_order/saleSteelOrder.vue

@@ -51,13 +51,6 @@
         >
           <el-table-column fixed="right" label="操作" width="180">
             <template slot-scope="scope">
-              <el-button
-                @click="updateCapacity(scope.row)"
-                type="text"
-                size="small"
-              >
-                修改运力
-              </el-button>
               <el-button
                 @click="detailclick2(scope.row)"
                 type="text"
@@ -65,13 +58,6 @@
               >
                 物资详情
               </el-button>
-              <el-button
-                @click="closeOrder(scope.row)"
-                type="text"
-                size="small"
-              >
-                关闭订单
-              </el-button>
             </template>
           </el-table-column>
           <!-- 物资详情抽屉 -->
@@ -113,13 +99,6 @@
               >
                 物资详情
               </el-button>
-              <el-button
-                @click="updateCapacity(scope.row)"
-                type="text"
-                size="small"
-              >
-                修改运力
-              </el-button>
             </template>
           </el-table-column>
           <!-- 物资详情抽屉 -->
@@ -202,13 +181,13 @@ export default {
         // option1请求数据的地址,承运商(运输订单状态为已接收,接收状态为已接收)
         requestUrl:
           "/api/v1/oms/getDriverInfoForSale?apiId=226&orderType=1&orderStatus=5&shipperId=1&carrierSsoId=" +
-          "",
+          ""
       },
       option2: {
         // option2请求数据的地址,承运商暂时设置为默认(运输订单状态为)
         requestUrl:
           "/api/v1/oms/getDriverInfoForSale?apiId=226&orderType=1&orderStatus=6&shipperId=1&carrierSsoId=" +
-          "",
+          ""
       },
       option3: {
         // option3请求数据的地址
@@ -216,11 +195,11 @@ export default {
           "/api/v1/oms/getDriverInfoForSale?apiId=226&orderType=1&orderStatus=4&shipperId=1&&carrierSsoId=" +
           "",
         selectionType: "select",
-        mapList: [],
+        mapList: []
       },
       truck: {
         requestUrl: "",
-        selectionType: "radio",
+        selectionType: "radio"
       },
       activeName: "third",
       //记录旧的row对象(已接收)
@@ -239,30 +218,30 @@ export default {
         {
           prop: "materialName",
           label: "物资名称",
-          width: 150,
+          width: 150
         },
         {
           prop: "specificationModel",
           label: "规格型号",
-          width: 150,
+          width: 150
         },
         {
           prop: "materialNumber",
           label: "物资件数",
-          width: 100,
+          width: 100
         },
         {
           prop: "materialWeight",
           label: "物资重量",
-          width: 100,
-        },
+          width: 100
+        }
       ],
       tableData: [],
       tableData1: [],
       tableData2: [],
       capacityId: null,
       dialogTableVisible: false,
-      orderId: null,
+      orderId: null
     };
   },
 
@@ -361,34 +340,34 @@ export default {
       if (this.option3.mapList.length == 0) {
         this.$message({
           type: "warning",
-          message: "请先选择要关闭的订单!",
+          message: "请先选择要关闭的订单!"
         });
       } else {
         this.$confirm("是否关闭这些订单", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
           type: "warning",
-          center: true,
+          center: true
         })
           .then(() => {
             //初始化maplist
             var mapList = [];
-            this.option3.mapList.forEach((item) => {
+            this.option3.mapList.forEach(item => {
               //初始化mapItem
               var mapItem = {
                 //销售订单物资中间表id
-                orderId: 0,
+                orderId: 0
               };
               mapItem.orderId = item.orderId;
               mapList.push(mapItem);
             });
             this.$message({
               type: "success",
-              message: "关闭成功!",
+              message: "关闭成功!"
             });
             this.axios
               .post("/api/v1/oms/batchCloseOrder", mapList)
-              .then((res) => {
+              .then(res => {
                 if (res.data.code == "200") {
                   this.getRequestUrl();
                 }
@@ -397,7 +376,7 @@ export default {
           .catch(() => {
             this.$message({
               type: "info",
-              message: "取消关闭!",
+              message: "取消关闭!"
             });
           });
       }
@@ -449,9 +428,9 @@ export default {
       this.axios
         .post("/api/v1/oms/updateCapacityId", {
           capacityId: this.capacityId,
-          orderId: this.orderId,
+          orderId: this.orderId
         })
-        .then((res) => {
+        .then(res => {
           if (res.data.code == "200") {
             this.$message.success("修改运力成功");
             this.getRequestUrl();
@@ -537,7 +516,7 @@ export default {
       // 根据销售订单id查询物资信息
       this.axios
         .post("/api/v1/oms/getOrderMaterialList?orderId=" + row.orderId)
-        .then((res) => {
+        .then(res => {
           console.log("res.data.data", res.data.data);
           this.tableData = res.data.data;
         });
@@ -569,7 +548,7 @@ export default {
       // 根据销售订单物资中间表id查询物资信息
       this.axios
         .post("/api/v1/oms/getOrderMaterialList?orderId=" + row.orderId)
-        .then((res) => {
+        .then(res => {
           console.log("res.data.data", res.data.data);
           this.tableData1 = res.data.data;
         });
@@ -601,7 +580,7 @@ export default {
       // 根据销售订单物资中间表id查询物资信息
       this.axios
         .post("/api/v1/oms/getOrderMaterialList?orderId=" + row.orderId)
-        .then((res) => {
+        .then(res => {
           this.tableData2 = res.data.data;
         });
     },
@@ -611,17 +590,17 @@ export default {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
         type: "warning",
-        center: true,
+        center: true
       })
         .then(() => {
           this.axios
             .post("/api/v1/oms/closeOrder?orderId=" + row.orderId)
-            .then((res) => {
+            .then(res => {
               if (res.data.code == "200") {
                 this.getRequestUrl();
                 this.$message({
                   type: "success",
-                  message: "关闭成功!",
+                  message: "关闭成功!"
                 });
               }
             });
@@ -629,11 +608,11 @@ export default {
         .catch(() => {
           this.$message({
             type: "info",
-            message: "取消关闭!",
+            message: "取消关闭!"
           });
         });
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss" scode>