From 3a8223b71d18205d40b894fd0b4c0fa1ca773e86 Mon Sep 17 00:00:00 2001
From: Lius <Lius2225@163.com>
Date: 星期一, 13 十一月 2023 10:44:11 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/mdc-test' into mdc-test

---
 src/views/eam/modules/dailyInspectionStandard/DailylnspectionStandardModal.vue |   77 +++++++++++++++++++++++++-------------
 1 files changed, 50 insertions(+), 27 deletions(-)

diff --git a/src/views/eam/modules/dailyInspectionStandard/DailylnspectionStandardModal.vue b/src/views/eam/modules/dailyInspectionStandard/DailylnspectionStandardModal.vue
index 355f36c..2100db5 100644
--- a/src/views/eam/modules/dailyInspectionStandard/DailylnspectionStandardModal.vue
+++ b/src/views/eam/modules/dailyInspectionStandard/DailylnspectionStandardModal.vue
@@ -31,25 +31,25 @@
           </a-col>
           <a-col :span="12">
             <a-form-item
-              label="瀵硅薄閮ㄩ棬"
+              label="浣跨敤閮ㄩ棬"
               :labelCol="labelCol"
               :wrapperCol="wrapperCol"
             >
-              <!-- <j-dict-select-tag
-                allow-clear
-                :disabled="disableSubmit"
-                :placeholder="disableSubmit?'':'璇烽�夋嫨瀵硅薄閮ㄩ棬'"
-                :triggerChange="true"
-                dictCode="mom_eam_equipment,use_id,id,status!='0' and del_flag!='1' and use_id!='null'"
-                v-decorator="['useId', validatorRules.useId]"
-              /> -->
-              <a-input-search
+              <!-- <a-input-search
                 :disabled="disableSubmit"
                 placeholder="璇烽�夋嫨瀵硅薄閮ㄩ棬"
                 enter-button
                 @search="onDepartList()"
                 :read-only="true"
                 v-decorator="['useDepartName', validatorRules.useDepartName]"
+              /> -->
+              <a-tree-select
+                style="width: 100%"
+                :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }"
+                :tree-data="treeData"
+                placeholder="璇烽�夋嫨浣跨敤閮ㄩ棬"
+                tree-default-expand-all
+                v-decorator="['useId', validatorRules.useId ]"
               />
             </a-form-item>
           </a-col>
@@ -104,7 +104,7 @@
               />
             </a-form-item>
           </a-col>
-          <a-col :span="12">
+          <!-- <a-col :span="12">
             <a-form-item
               label="瀵硅薄閮ㄩ棬Id"
               :labelCol="labelCol"
@@ -117,7 +117,7 @@
                 v-decorator="['useId', validatorRules.useId ]"
               />
             </a-form-item>
-          </a-col>
+          </a-col> -->
         </a-row>
         <a-row :gutter="24">
           <a-col :span="12">
@@ -201,6 +201,7 @@
       rowKey='id'
       :columns="columns"
       :dataSource="dataSource"
+      :pagination="false"
     >
       <template
         v-for="col in columns"
@@ -320,21 +321,21 @@
           align: 'center',
           dataIndex: 'detectionStandard'
         },
-        {
-          title: '鍚堟牸鑼冨洿',
-          align: 'center',
-          dataIndex: 'acceptabilityLimit'
-        },
-        {
-          title: '鏂规硶',
-          align: 'center',
-          dataIndex: 'inspectionMethodName'
-        },
-        {
-          title: '宸ュ叿',
-          align: 'center',
-          dataIndex: 'inspectionTool'
-        },
+        // {
+        //   title: '鍚堟牸鑼冨洿',
+        //   align: 'center',
+        //   dataIndex: 'acceptabilityLimit'
+        // },
+        // {
+        //   title: '鏂规硶',
+        //   align: 'center',
+        //   dataIndex: 'inspectionMethodName'
+        // },
+        // {
+        //   title: '宸ュ叿',
+        //   align: 'center',
+        //   dataIndex: 'inspectionTool'
+        // },
         {
           title: '鍛ㄦ湡',
           align: 'center',
@@ -372,6 +373,7 @@
       isRevise: false,
       model: {},
       inspectionCycles: {},
+      treeData: [],
       labelCol: {
         xs: { span: 24 },
         sm: { span: 6 },
@@ -416,6 +418,8 @@
         getInspectionCycle: "/eam/inspectionStandardDetail/getInspectionCycle",
         revise: '/eam/inspectionStandard/revise',
         getReviseVersion: "/eam/inspectionStandard/getReviseVersion",
+        loadOptions: '/sys/sysDepart/loadDepartTreeOptions',
+        getNum: '/eam/sysIdentity/getNumNew'
       },
 
       dataSource: [],
@@ -456,11 +460,13 @@
 
     add() {
       this.edit({ dailyInspectionStandardDetaillist: [] })
+      this.getSeq()
     },
 
     edit(record) {
       let that = this;
       that.getInspectionCycle()
+      that.initOptions();
       that.dataSource = [];
       that.form.resetFields();
       that.model = Object.assign({}, record);
@@ -491,6 +497,23 @@
       }
     },
 
+    getSeq() {
+      getAction(this.url.getNum, { type: 'DailylnspectionStandard', length: 4 }).then(res => {
+        if (res.success) {
+          this.form.setFieldsValue({ "num": res.result })
+        }
+      })
+    },
+
+    initOptions() {
+      getAction(this.url.loadOptions).then(res => {
+        if (res.success) {
+          this.treeData = res.result
+        } else {
+          this.$message.warning(res.message)
+        }
+      })
+    },
     onEquipmentList() {
       let data = this.form.getFieldsValue(['useId']);
       this.$refs.EquipmentList.list(data.useId);

--
Gitblit v1.9.3