huk 3 gadi atpakaļ
vecāks
revīzija
1d51376f94

+ 1 - 1
build/utils.js

@@ -16,7 +16,7 @@ const devPathSrc = path.resolve(__dirname, '../../../src'); // node_modules应
 //       统计报表       组织机构/系统管理 采购  仓储
 //  'statisticalReport','systemConfig','TMS','WMS','workFlow']
 // let devModules = ['all'];
-let devModules = ['index','statisticalReport','TMS'];
+let devModules = ['index','statisticalReport','TMS','RMS'];
 if (pathSrc.indexOf('node_modules') > -1) {
     devModules = require('../../../cors.js').devModules;
 }

+ 1 - 1
config/index.js

@@ -58,7 +58,7 @@ let proxyTable = {
   "/api/v1": {
     target: "http://172.16.33.166:8080",
     // target: "http://172.16.33.162:8019",
-    // target: "http://192.168.1.109:8019",
+    // target: "http://localhost:8019",
     ws: true,
     pathRewrite: {
       "^/api/v1": "/api/v1"

+ 12 - 21
src/components/DilCommonUI/packages/table/src/table.js

@@ -19,7 +19,7 @@ export default {
       // 自己的每页显示条目个数
       dataPageSize: 10,
       // 保存表格所有页面所选中的数据
-      dataSelection: [],
+      dataRadioId: [],
       // 保存表格单选的数据 保存数据的id
       dataRadioId: ""
     };
@@ -65,24 +65,18 @@ export default {
           // 判断是否需要在请求体中放入参数
           if(this.requestQuery){
             console.log(" 判断是否需要在请求体中放入参数")
-            
             this.dataRequestQuery=this.requestQuery;
             // console.log(this.dataRequestQuery.resultBreakId)
           }
-
           let data = undefined;
           for (const key in this.dataRequestQuery) {
-         
             const val = this.dataRequestQuery[key];
             console.log(val)
             if (val||val==0) {
-             
               if (!data) data = {};
-            
               data[key] = val;
             }
           }
-        
           // 发送请求
           this.axios
             .post(url, data, {
@@ -99,7 +93,6 @@ export default {
               //执行成功的回调
               this.$emit('func',response.data.data);
               this.refreshColumnData(d.columnData);
-
               this.isShow = true;
             });
         }
@@ -109,12 +102,10 @@ export default {
     },
     // 刷新表头显示数据
     refreshColumnData(columnData) {
-      // 表头只赋值一次
-      if (this.dataColumnData.length > 0) return;
-
+      // 表头只赋值一次(在查出全部数据的情况下才只赋值一次)
+      // if (this.dataColumnData.length > 0) return;
       // 如果前端有写表头,则加在后端表头前面
       const d = this.columnData.concat(columnData);
-
       // 把操作列拼接到最后一列
       this.dataColumnData = d;
       this.dataDropColumn = [].concat(this.dataColumnData);
@@ -174,15 +165,15 @@ export default {
     },
     // 当某一行被点击时会触发该事件
     rowClick(row, column, event) {
-      // if (this.selectionType == "radio") {
-      //   if (this.dataRadioId == row.ROW_ID) {
-      //     this.dataRadioId = "";
-      //     row = {};
-      //   } else {
-      //     this.dataRadioId = row.ROW_ID;
-      //   }
+      if (this.selectionType == "radio") {
+        if (this.dataRadioId == row.ROW_ID) {
+          this.dataRadioId = "";
+          row = {};
+        } else {
+          this.dataRadioId = row.ROW_ID;
+        }
         this.$emit("radio-change", row);
-      // }
+      }
     },
     // 多选的选中行改变回调
     selectionChange(selection) {
@@ -233,11 +224,11 @@ export default {
     },
     // current-page 改变时会触发
     currentChange(val, isRequest = true) {
-      this.dataCurrentPage = val;
       if (isRequest) {
         this.requestData({ pageNum: val });
       }
       // 最后通知父节点页面改变
+      this.dataCurrentPage = val;
       this.$emit("update:current-page", val);
     },
     // pageSize 改变时会触发

+ 3 - 0
src/components/DilCommonUI/packages/table/src/table.vue

@@ -116,6 +116,9 @@ export default {
   name: "DilTable",
   extends: table,
   props: {
+    isChang:{
+      default:false,
+    },
     // 请求地址
     requestUrl: {
       default: "",

+ 18 - 0
src/views/RMS/components/addCapacity.vue

@@ -128,7 +128,25 @@ export default {
           }
         })
     },
+    isVehicleNumber(vehicleNumber) {
+				  console.log(vehicleNumber)
+			      var result = false;
+			      if (vehicleNumber.length == 7){
+			        var express = /^[京津沪渝冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤青藏川宁琼使领A-Z]{1}[A-Z]{1}[A-Z0-9]{4}[A-Z0-9挂学警港澳]{1}$/;
+			        result = express.test(vehicleNumber);
+			      }
+			      return result;
+				  
+		},
     makeSure() {
+        if(!this.isVehicleNumber(this.form1.capacityNumber.toUpperCase())){
+            this.$message.error("车牌号格式不正确")
+            return
+        }
+        if(this.carrierIds == null){
+            this.$message.error("请选择承运商")
+            return
+        }
         let RmsCapacity = {
         capacityTypeId: this.form1.capacityTypeId,
         capacityNumber: this.form1.capacityNumber.toUpperCase(),

+ 3 - 3
src/views/TMS/components/purchaseChemicalMaterials/transportationReservationAdd.vue

@@ -325,9 +325,9 @@ export default {
               this.purchaseOrderId = res.data.data.purchaseOrderId;
               this.purchaseOrderNo=res.data.data.purchaseOrderNo;
               if (res.data.data.receiveUnitId == 1) {
-                this.orderType = 6;
+                this.orderType = 17;
               } else {
-                this.orderType = 7;
+                this.orderType = 18;
               }
             }
           } else {
@@ -530,7 +530,7 @@ export default {
               message: "添加成功!",
               type: "success",
             });
-            this.$router.push("/transportReserveRan");
+            this.$router.push("/transportationReservation");
           }
         });
       }

+ 40 - 23
src/views/appoint/components/saleContract/addSaleOrderArrange.vue

@@ -12,12 +12,6 @@
       <el-button type="primary" @click="arragne">确定排车</el-button>
     </div>
 
-    <!-- <div class="table_form from">
-      <div class="materialId">
-        <span class="text"> 物资: </span>
-        <el-button type="primary" class="btn" @click="table = true">浏览</el-button>
-      </div>
-    </div> -->
     <!-- 车序号表格 -->
     <div class="switch" v-if="selectionList.length > 0">
       <el-tooltip placement="top">
@@ -93,6 +87,7 @@
                   class="textinput1"
                   placeholder="(必填)"
                   v-model.number="scope.row.cxh"
+                  @change="updateArragneCxh(scope.row.cxh)"
                 ></el-input>
               </template>
               <!-- 收货地址id -->
@@ -162,12 +157,11 @@
 
             <el-input
             style="width: 50px;"
-              placeholder="(非必填)"
               v-model.number="scope.row.arragneCount"
             ></el-input>
 
             <el-button
-              @click="deleteRow(scope.$index)"
+              @click="deleteRow(scope.$index,scope.row)"
               type="text"
               icon="el-icon-close"
               size="big"
@@ -227,7 +221,7 @@
 </template>
 <script>
 import PageTitle from "@/components/Page/Title";
-
+import { sjTime,isNumber } from "@/utils/sharedJsFile";
 export default {
   components: { PageTitle },
   data() {
@@ -360,31 +354,40 @@ export default {
       this.row.index = index;
       this.drawer = true;
     },
+    //修改输入框中的车序号,自动获取车序号最大值
+    updateArragneCxh(cxh){
+      if(this.arragneCxh<cxh){
+          this.arragneCxh = ++cxh;
+      }
+    },
     //复制多条的方法
     copyRow(index,row){
-      console.log("this.selectionList",this.selectionList)
-      console.log("row",row)
       let arr = [];
       for(var i = 0 ;i<this.selectionList.length; i++){
         if(i == index){
           arr.push(this.selectionList[i]);
+          //车序号自增
+          var cxhStart = row.cxh;
           for(var j = 0;j<this.selectionList[i].arragneCount; j++){
             arr.push({
             Specification:row.Specification,
             arragneCount:this.arragneCount,
-            cxh:row.cxh,
+            cxh:++cxhStart,
             materialName:row.materialName,
             orderPlanWeight:row.orderPlanWeight,
             saleDateOfReceipt:row.saleDateOfReceipt,
             saleMaterialId:row.saleMaterialId,
             saleOrderConsignee:row.saleOrderConsignee,
-            saleDateOfReceipt:row.saleDateOfReceipt,
             saleOrderConsigneeTel:row.saleOrderConsigneeTel,
             saleShipperAddressId:row.saleShipperAddressId,
             saleShipperAddressName:row.saleShipperAddressName,
           })
 
           }
+          //确定车序号最大值并赋值给初始化车序号
+          if(this.arragneCxh<cxhStart){
+            this.arragneCxh = ++cxhStart;
+          }
         }else{
           arr.push(this.selectionList[i]);
         }
@@ -393,8 +396,28 @@ export default {
       this.selectionList = arr;
     },
     //点击删除按钮删除当前点击的对象
-    deleteRow(index){
-      this.selectionList.splice(index,1)
+    deleteRow(index,row){
+      //统计与当前最大车序号相等的车序号
+      var equalArragneCxh = 0;
+      //若为最后一个删除对象,初始化this.arragneCxh的值
+      if(this.selectionList.length==1){
+        this.arragneCxh = 1;
+      }else{
+        for(var i = 0 ;i<this.selectionList.length; i++){
+          if(this.selectionList[i].cxh==this.arragneCxh){
+            equalArragneCxh++;
+          }
+        }
+        //判断是否要减小最大车序号数
+        if(equalArragneCxh==0){
+          if((this.arragneCxh-1)==row.cxh){
+          this.arragneCxh=row.cxh;
+          }
+        }
+      }
+      
+      //删除当前点击的对象
+      this.selectionList.splice(index,1);
     },
     //监听模态框点击事件
     currentRadioChange1(radioList) {
@@ -423,7 +446,6 @@ export default {
             saleDateOfReceipt:e.saleDateOfReceipt,
             saleMaterialId:e.saleMaterialId,
             saleOrderConsignee:e.saleOrderConsignee,
-            saleDateOfReceipt:e.saleDateOfReceipt,
             saleOrderConsigneeTel:e.saleOrderConsigneeTel,
             saleShipperAddressId:e.saleShipperAddressId,
             saleShipperAddressName:e.saleShipperAddressName,
@@ -481,8 +503,6 @@ export default {
           arragneCount : this.arragneCount,
         };
         this.selectionList.push(addmap);
-        //车序号自增
-        this.arragneCxh++;
       });
       this.selectionList1 = [];
       this.table = false;
@@ -493,13 +513,11 @@ export default {
     selectionChange(selection) {
       this.selectionList1 = [];
       this.selectionList1 = selection;
-      console.log("this.selectionList1 ",this.selectionList1)
     },
     // 确定
     makeSure() {
         //初始化maplist
       var mapList = [];
-      console.log("this.selectionList",this.selectionList)
       this.selectionList.forEach((item,i) => {
         //初始化mapItem
         var mapItem={
@@ -509,7 +527,7 @@ export default {
                 truckNo : "",
                 //收货地址id
                 shippingAddressId : 0,
-                //收货日期
+                //截止日期
                 dateOfReceipt :null,
                 //收货方姓名   
                 orderConsignee :"",
@@ -523,14 +541,13 @@ export default {
         mapItem.saleOrderId=this.$route.params.saleOrderId;
         mapItem.truckNo=item.cxh;
         mapItem.shippingAddressId=item.saleShipperAddressId;
-        mapItem.dateOfReceipt=item.saleDateOfReceipt;
+        mapItem.dateOfReceipt=sjTime(item.saleDateOfReceipt);
         mapItem.orderConsignee=item.saleOrderConsignee;
         mapItem.orderConsigneeTel=item.saleOrderConsigneeTel;
         mapItem.saleMaterialId=item.saleMaterialId;
         mapItem.materialNumber=item.orderPlanWeight;
         mapList.push(mapItem);
       });
-      console.log("mapList",mapList);
         this.axios.post("/api/v1/ams/addTruckNo", mapList).then((res) => {
           if (res.data.code == "200") {
             this.$router.go(-1);

+ 1 - 0
src/views/inward/components/inwardImport/oldAreaRailScale/qualityResult.vue

@@ -18,6 +18,7 @@
     </div>
 </template>
 <script>
+import { getCookie } from "@/utils/util.js";
 export default {
     data(){
         return{

+ 26 - 23
src/views/inward/components/truckAppoint/addRequirement.vue

@@ -17,13 +17,17 @@
       <el-input class="input" v-model="unloadPointName" disabled> </el-input>
       <el-button type="primary" @click="ondrawer(4)">浏览</el-button>
     </div>
-    <div class="forwardingUnit from">
+    <div class="purchaseOrderNo from">
+      <span class="text">采购订单号:</span>
+      <el-input class="input" v-model="purchaseOrderNo" disabled> </el-input>
+    </div>
+    <div class="carrier from">
        <el-form
         :inline="true"
         class="demo-form-inline"
         label-width="80px"
       >
-        <el-form-item label="选择承运商">
+        <el-form-item label="选择承运商:">
          <el-autocomplete
           class="inline-input"
           v-model="stateCarrier"
@@ -39,9 +43,6 @@
         </el-form-item>
     </el-form>
     </div>
-    <div class="contractTitle from">
-      <dil-form :formId="219" v-model="form1"></dil-form>
-    </div>
     <!-- 模态窗口 -->
     <el-drawer :visible.sync="drawer" :direction="direction" size="40%">
       <div style="margin-bottom: 10px">
@@ -109,6 +110,8 @@ export default {
 
       // 表单
       form1: {},
+      //采购订单号
+      purchaseOrderNo:"",
       //采购订单id
       purchaseOrderId: "",
       //物资名称
@@ -191,12 +194,7 @@ export default {
               console.log();
               this.remark = res.data.data.remark;
               this.purchaseOrderId = res.data.data.purchaseOrderId;
-              this.form1 = { purchaseOrderNo: res.data.data.purchaseOrderNo };
-              if (res.data.data.receiveUnitId == 1) {
-                this.orderType = 6;
-              } else {
-                this.orderType = 7;
-              }
+              this.purchaseOrderNo = res.data.data.purchaseOrderNo ;           
             }
           } else {
             this.$message.error("请求失败");
@@ -433,18 +431,23 @@ export default {
     margin-right: 20px;
   }
 }
-.truckList1 {
-  width: 100%;
-  .truckList {
-    width: 96%;
-    .text {
-      display: inline-block;
-      width: 120px;
-      text-align: right;
-    }
-    .truckBtn {
-      width: 250px;
-    }
+.purchaseOrderNo{
+  display: flex;
+  justify-content: center;
+  .text{
+    display: inline-block;
+    width: 170px;
+    text-align: right;
+  }
+  .input {
+    width: 250px;
+    margin-right: 90px;
+  }
+}
+.carrier{
+  display: flex;
+  .el-autocomplete{
+    width: 250px;
   }
 }
 .button_box {