Browse Source

代码修改

chen 2 years ago
parent
commit
3247ae531f

+ 26 - 0
src/option/product/product.js

@@ -236,5 +236,31 @@ export default {
       viewDisplay: false,
       hide: true,
     },
+    {
+      label: "扫码日期",
+      prop: "scanDateArr",
+      search: true,
+      searchType: "daterange",
+      format: "YYYY-MM-DD",
+      valueFormat: "YYYY-MM-DD",
+      dataType:'string',
+      searchRange:true,
+      addDisplay: false,
+      editDisplay: false,
+      hide: true
+    },
+    {
+      label: "创建时间",
+      prop: "createTimeArr",
+      search: true,
+      searchType: "daterange",
+      format: "YYYY-MM-DD",
+      valueFormat: "YYYY-MM-DD",
+      dataType:'string',
+      searchRange:true,
+      addDisplay: false,
+      editDisplay: false,
+      hide: true
+    },
   ]
 }

+ 11 - 11
src/option/productBatch/product.js

@@ -44,17 +44,17 @@ export default {
         trigger: "blur"
       }]
     },
-    {
-      label: "订单号",
-      prop: "orderNo",
-      type: "input",
-      cell: true,
-      rules: [{
-        required: true,
-        message: "请填写订单号",
-        trigger: "blur"
-      }]
-    },
+    // {
+    //   label: "订单号",
+    //   prop: "orderNo",
+    //   type: "input",
+    //   cell: true,
+    //   rules: [{
+    //     required: true,
+    //     message: "请填写订单号",
+    //     trigger: "blur"
+    //   }]
+    // },
     // {
     //   label: "出货批次",
     //   prop: "shipmentBatch",

+ 30 - 1
src/option/productBatch/productBatch.js

@@ -39,6 +39,7 @@ export default {
       hide: getStore({ name: 'userInfo' }).user_category!=1,
       display: getStore({ name: 'userInfo' }).user_category==1,
       type: "tree",
+      cascader: [getStore({ name: 'userInfo' }).user_category==1?'clientId':'',getStore({ name: 'userInfo' }).user_category==1?'productModelId':''],
       dicUrl: "/api/pl-factory/factory/select",
       props: {
         label: "name",
@@ -58,13 +59,31 @@ export default {
       addDisplay: false,
       editDisplay: false,
     },
+    
+    {
+      label: "所属客户",
+      prop: "clientId",
+      type: "input",
+      search: true,
+      type: "tree",
+      dicUrl: "/api/pl-client/client/select?factoryId={{factoryId}}",
+      props: {
+        label: "name",
+        value: "id",
+      },
+      rules: [{
+        required: true,
+        message: "请选择所属客户",
+        trigger: "blur"
+      }]
+    },
     {
       label: "产品型号",
       prop: "productModelId",
       type: "input",
       search: true,
       type: "tree",
-      dicUrl: "/api/pl-productModel/productModel/select",
+      dicUrl: "/api/pl-productModel/productModel/select?factoryId={{factoryId}}",
       props: {
         label: "productName",
         value: "id",
@@ -96,6 +115,16 @@ export default {
       viewDisplay: false,
       hide: true,
     },
+    {
+      label: "订单号",
+      prop: "orderNo",
+      type: "input",
+      rules: [{
+        required: true,
+        message: "请填写订单号",
+        trigger: "blur"
+      }]
+    },
     {
       label: "创建人",
       prop: "createUser",

+ 12 - 12
src/option/productModel/productModel.js

@@ -44,18 +44,18 @@ export default {
         value: "id",
       },
     },
-    {
-      label: "所属客户",
-      prop: "clientId",
-      type: "input",
-      search: true,
-      type: "tree",
-      dicUrl: "/api/pl-client/client/select?factoryId={{factoryId}}",
-      props: {
-        label: "name",
-        value: "id",
-      },
-    },
+    // {
+    //   label: "所属客户",
+    //   prop: "clientId",
+    //   type: "input",
+    //   search: true,
+    //   type: "tree",
+    //   dicUrl: "/api/pl-client/client/select?factoryId={{factoryId}}",
+    //   props: {
+    //     label: "name",
+    //     value: "id",
+    //   },
+    // },
     {
       label: "产品名称",
       prop: "productName",

+ 39 - 25
src/option/productRework/productRework.js

@@ -77,6 +77,17 @@ export default {
       type: "input",
       search: true,
     },
+    {
+      label: "状态",
+      prop: "status",
+      addDisplay: false,
+      editDisplay: false,
+      type:"select",
+      dataType:"number",
+      dicUrl:"/blade-system/dict-biz/dictionary?code=repair_status",
+      props:{label:"dictValue",value:"dictKey"},
+      search: true,
+    },
     {
       label: "报修图片",
       prop: "repairsImgs",
@@ -89,15 +100,37 @@ export default {
       span:24
     },
     {
-      label: "维修时间",
-      prop: "reworkDate",
+      label: "问题描述",
+      prop: "problemDesc",
       type: "input",
+      addDisplay: false,
+      editDisplay: false,
+      hide: true,
+      span:24
+    },
+    {
+      label: "上报人",
+      prop: "createPersonName",
+      type: "input",
+      addDisplay: false,
+      editDisplay: false,
+    },
+    {
+      label: "上报日期",
+      prop: "createTime",
+      type: "input",
+      addDisplay: false,
+      editDisplay: false,
     },
     {
       label: "维修人",
       prop: "reworkPersonName",
       type: "input",
-      hide: true,
+    },
+    {
+      label: "维修时间",
+      prop: "reworkDate",
+      type: "input",
     },
     {
       label: "维修图片",
@@ -110,27 +143,15 @@ export default {
       listType: 'picture-img',
       span:24
     },
-    {
-      label: "审核时间",
-      prop: "auditDate",
-      type: "input",
-    },
     {
       label: "审核人",
       prop: "auditPersonName",
       type: "input",
-      hide: true,
     },
     {
-      label: "状态",
-      prop: "status",
-      addDisplay: false,
-      editDisplay: false,
-      type:"select",
-      dataType:"number",
-      dicUrl:"/blade-system/dict-biz/dictionary?code=repair_status",
-      props:{label:"dictValue",value:"dictKey"},
-      search: true,
+      label: "审核时间",
+      prop: "auditDate",
+      type: "input",
     },
     {
       label: "创建人",
@@ -150,13 +171,6 @@ export default {
       viewDisplay: false,
       hide: true,
     },
-    {
-      label: "创建时间",
-      prop: "createTime",
-      type: "input",
-      addDisplay: false,
-      editDisplay: false,
-    },
     {
       label: "修改人",
       prop: "updateUser",

+ 12 - 4
src/views/productBatch/productBatch.vue

@@ -249,13 +249,17 @@
         const {
           batchNo,
           productName,
-          productModel,
+          clientId,
+          factoryId,
+          productModelId
         } = this.query;
 
         let values = {
-          batchNo_: batchNo,
-          productName_: productName,
-          productModel_: productModel,
+          batchNo_like: batchNo,
+          productName_like: productName,
+          productModelId: productModelId,
+          clientId: clientId,
+          factoryId: factoryId,
         };
 
         getList(page.currentPage, page.pageSize, values).then(res => {
@@ -264,6 +268,10 @@
           this.data = data.records;
           this.loading = false;
           this.selectionClear();
+          this.$nextTick(() => {
+            //放在数据加载完后执行
+            this.$refs.crud.dicInit('cascader');
+          })
         });
       }
     }

+ 4 - 0
src/views/productModel/productModel.vue

@@ -227,6 +227,10 @@
           this.data = data.records;
           this.loading = false;
           this.selectionClear();
+          this.$nextTick(() => {
+            //放在数据加载完后执行
+            this.$refs.crud.dicInit('cascader');
+          })
         });
       }
     }