From 86d99e38a2c44e85983d2b8adccf332902a8f2a2 Mon Sep 17 00:00:00 2001
From: “linengliang” <vanSuperEnergy@163.com>
Date: 星期五, 15 三月 2024 15:00:56 +0800
Subject: [PATCH] xg

---
 src/views/eam/modules/daily3MaintenanceOrder/Maintenance3ReceiptModal.vue |   72 ++++++++++++++++++++++++++++++-----
 1 files changed, 61 insertions(+), 11 deletions(-)

diff --git a/src/views/eam/modules/daily3MaintenanceOrder/Maintenance3ReceiptModal.vue b/src/views/eam/modules/daily3MaintenanceOrder/Maintenance3ReceiptModal.vue
index 43b0850..a9d7d6a 100644
--- a/src/views/eam/modules/daily3MaintenanceOrder/Maintenance3ReceiptModal.vue
+++ b/src/views/eam/modules/daily3MaintenanceOrder/Maintenance3ReceiptModal.vue
@@ -7,14 +7,20 @@
     cancelText="鍏抽棴"
     @cancel="handleCancel"
     :confirmLoading="confirmLoading"
+    title="闄勫綍4"
   >
     <!-- :title="title" -->
     <a-spin :spinning="confirmLoading">
       <a-form :form="form">
+        <span
+          class="ant-descriptions-title"
+          style="font-size: large;font-size: 15px;float: right;"
+        >{{this.model.receiptsNum}}</span>
         <a-divider
           orientation="center"
           style="font-size: large;font-style: normal;font-size: 30px;color: #66aeed;"
-        > 鐢熶骇璁惧涓夌骇淇濆吇楠屾敹鍗� </a-divider>
+        > {{this.model.receiptsName}} </a-divider>
+        <!-- 鐢熶骇璁惧涓夌骇淇濆吇楠屾敹鍗� -->
         <a-row :gutter="24">
           <a-col :span="8">
             <a-form-item
@@ -77,6 +83,7 @@
                 auto-size
                 placeholder="璇疯緭鍏ヤ繚鍏诲唴瀹�"
                 @change="(e)=>handleChange(e, record.key, col, index)"
+                :disabled="true"
               />
               <a-textarea
                 :value="text"
@@ -85,7 +92,7 @@
                 auto-size
                 placeholder="璇疯緭鍏ヤ繚鍏绘爣鍑�"
                 @change="(e)=>handleChange(e, record.key, col, index)"
-                :disabled="false"
+                :disabled="true"
               />
               <a-select
                 v-if="col.dataIndex == 'firstInspect'"
@@ -96,6 +103,12 @@
                 <a-select-option value="1">閫氳繃</a-select-option>
                 <a-select-option value="2">鏈�氳繃</a-select-option>
               </a-select>
+              <a-input
+                v-if="col.dataIndex == 'firstInspect'"
+                @change="(e)=>handleChange(e, record.key, col, index)"
+                :disabled="false"
+                placeholder="璇峰~鍐欓獙鏀舵湭閫氳繃鍘熷洜"
+              />
               <a-select
                 v-if="col.dataIndex == 'secondInspect'"
                 :value="text"
@@ -109,8 +122,8 @@
             </div>
           </template>
         </a-table>
-        <!-- <div :style="{height: '140px',width: '100%',border: '1px solid #e9e9e9',padding: '10px 16px',background: '#fff',}">
-          <a-row :gutter="24">
+        <div :style="{height: '140px',width: '100%',border: '1px solid #e9e9e9',padding: '10px 16px',background: '#fff',}">
+          <!-- <a-row :gutter="24">
             <a-col :span="12">
               <a-form-item
                 :labelCol="labelCol"
@@ -119,25 +132,26 @@
               >
               </a-form-item>
             </a-col>
-          </a-row>
+          </a-row> -->
           <a-row :gutter="24">
             <a-col :span="24">
               <a-form-item
                 :labelCol="{span:3}"
                 :wrapperCol="{span:21}"
-                label="澶囨敞"
+                label="楠屾敹鏈�氳繃鍘熷洜"
               >
                 <a-textarea
                   allow-clear
+                  :rows='5'
                   :disabled="disableSubmit"
-                  :placeholder="disableSubmit?'':'璇疯緭鍏ュ娉�'"
-                  v-decorator="['remark', {}]"
+                  :placeholder="disableSubmit?'':'璇疯緭鍏ラ獙鏀舵湭閫氳繃鍘熷洜'"
+                  v-decorator="['notPassReason', {}]"
                 />
-              
+
               </a-form-item>
             </a-col>
           </a-row>
-        </div> -->
+        </div>
       </a-form>
     </a-spin>
 
@@ -234,6 +248,23 @@
           dataIndex: 'standard',
           scopedSlots: { customRender: 'standard' }
         },
+        // {
+        //   title: '楠屾敹娆℃暟',
+        //   children: [
+        //     {
+        //       title: '绗竴娆℃',
+        //       dataIndex: 'firstInspect',
+        //       align: 'center',
+        //       scopedSlots: { customRender: 'firstInspect' }
+        //     },
+        //     {
+        //       title: '绗簩娆℃',
+        //       dataIndex: 'secondInspect',
+        //       align: 'center',
+        //       scopedSlots: { customRender: 'secondInspect' }
+        //     },
+        //   ],
+        // },
         {
           title: '绗竴娆℃',
           align: 'center',
@@ -268,6 +299,7 @@
         add: "/eam/maintenanceThreeAcceptance/add",
         getMaintenance3Receipt: "/eam/maintenanceThreeAcceptance/getMaintenanceThreeAcceptanceList",
         list: "/eam/dailyMaintenanceOrder/getMaintenanceCycleByStandardId",
+        getSysFileName: "/eam/sysFileName/getSysFileName",
       },
     }
   },
@@ -280,12 +312,15 @@
 
     edit(record) {
       let that = this;
+      if (record.receipts == "" || record.receipts == null) {
+        this.getSysFileName()
+      }
       this.form.resetFields();
       this.model = Object.assign({}, record);
       this.visible = true;
       this.getMaintenance3Receipt()
       that.$nextTick(() => {
-        // that.form.setFieldsValue(pick(that.model, 'num', 'teamId', 'remark'));
+        that.form.setFieldsValue(pick(that.model, 'notPassReason'));
       });
 
     },
@@ -311,6 +346,13 @@
 
       const that = this;
       // 瑙﹀彂琛ㄥ崟楠岃瘉
+      for (let i = 0; i < that.dataSource.length; i++) {
+        let o = that.dataSource[i]
+        if (o.firstInspect == "2" && o.secondInspect == "2") {
+          that.$message.warning("楠屾敹鍗曠" + (i + 1) + "琛岋紝涓ゆ妫�楠屽潎涓轰笉閫氳繃锛岃閲嶆柊妫�楠岃椤逛繚鍏诲唴瀹癸紒");
+          return
+        }
+      }
       that.form.validateFields((err, values) => {
         if (!err) {
           this.$confirm({
@@ -365,6 +407,14 @@
       }
     },
 
+    getSysFileName() {
+      getAction(this.url.getSysFileName, { name: '19' }).then((res) => {
+        if (res.success) {
+          this.model = Object.assign(this.model, res.result[0]);
+        }
+      })
+    },
+
   },
 }
 </script>

--
Gitblit v1.9.3