From 1392d8f3def2c21e7a6fc15cf3f68fc1056ec0b6 Mon Sep 17 00:00:00 2001
From: lyh <925863403@qq.com>
Date: 星期二, 29 七月 2025 19:01:20 +0800
Subject: [PATCH] 三不原则

---
 src/views/eam/technical/EamTechnicalStatusEvaluationOrderList.vue |  209 +++++++++++++++++++++++++++++++++++----------------
 1 files changed, 143 insertions(+), 66 deletions(-)

diff --git a/src/views/eam/technical/EamTechnicalStatusEvaluationOrderList.vue b/src/views/eam/technical/EamTechnicalStatusEvaluationOrderList.vue
index 2232cf7..92eb74e 100644
--- a/src/views/eam/technical/EamTechnicalStatusEvaluationOrderList.vue
+++ b/src/views/eam/technical/EamTechnicalStatusEvaluationOrderList.vue
@@ -1,74 +1,111 @@
 <template>
   <a-card :bordered="false">
-    <!-- 鏌ヨ鍖哄煙 -->
-    <div class="table-page-search-wrapper">
-      <a-form layout="inline" @keyup.enter.native="searchQuery">
-        <a-row :gutter="24">
-          <a-col :xl="5" :lg="6" :md="8" :sm="12">
-            <a-form-item label="缁熶竴缂栫爜">
-              <lx-search-equipment-select placeholder="璇疯緭鍏ョ粺涓�缂栫爜鎴栧悕绉版悳绱�" v-model="queryParam.equipmentId"/>
-            </a-form-item>
-          </a-col>
-          <a-col :xl="5" :lg="6" :md="8" :sm="12">
-            <a-form-item label="宸ュ崟鍙�">
-              <a-input placeholder="璇疯緭鍏ュ伐鍗曞彿" v-model="queryParam.orderNum"/>
-            </a-form-item>
-          </a-col>
-          <a-col :xl="5" :lg="6" :md="8" :sm="12">
-            <a-form-item label="璁″垝閴村畾鏃ユ湡">
-              <a-date-picker v-model="queryParam.evaluationDate" style="width: 100%"/>
-            </a-form-item>
-          </a-col>
-          <a-col :xl="5" :lg="6" :md="8" :sm="12">
-            <a-form-item label="閴村畾鐘舵��">
-              <j-dict-select-tag placeholder="璇烽�夋嫨閴村畾鐘舵��" dict-code="technical_status_evaluation_order_status"
-                                 v-model="queryParam.evaluationStatus"/>
-            </a-form-item>
-          </a-col>
-          <a-col :xl="4" :lg="6" :md="8" :sm="12">
+    <template v-if="isDisplayOperation">
+      <!-- 鏌ヨ鍖哄煙 -->
+      <div class="table-page-search-wrapper">
+        <a-form layout="inline" @keyup.enter.native="searchQuery">
+          <a-row :gutter="24">
+            <a-col :xl="5" :lg="6" :md="8" :sm="12">
+              <a-form-item label="缁熶竴缂栫爜">
+                <lx-search-equipment-select placeholder="璇疯緭鍏ョ粺涓�缂栫爜鎴栧悕绉版悳绱�" v-model="queryParam.equipmentId"/>
+              </a-form-item>
+            </a-col>
+            <a-col :xl="5" :lg="6" :md="8" :sm="12">
+              <a-form-item label="宸ュ崟鍙�">
+                <a-input placeholder="璇疯緭鍏ュ伐鍗曞彿" v-model="queryParam.orderNum"/>
+              </a-form-item>
+            </a-col>
+            <a-col :xl="5" :lg="6" :md="8" :sm="12">
+              <a-form-item label="璁″垝閴村畾鏃ユ湡">
+                <a-date-picker v-model="queryParam.evaluationDate" style="width: 100%"/>
+              </a-form-item>
+            </a-col>
+            <a-col :xl="5" :lg="6" :md="8" :sm="12">
+              <a-form-item label="閴村畾鐘舵��">
+                <j-dict-select-tag placeholder="璇烽�夋嫨閴村畾鐘舵��" dict-code="technical_status_evaluation_order_status"
+                                   v-model="queryParam.evaluationStatus"/>
+              </a-form-item>
+            </a-col>
+            <a-col :xl="4" :lg="6" :md="8" :sm="12">
             <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
               <a-button type="primary" @click="searchQuery" icon="search">鏌ヨ</a-button>
               <a-button type="info" @click="searchReset" icon="reload" style="margin-left: 8px">閲嶇疆</a-button>
             </span>
-          </a-col>
-        </a-row>
-      </a-form>
-    </div>
+            </a-col>
+          </a-row>
+        </a-form>
+      </div>
 
-    <!-- 鎿嶄綔鎸夐挳鍖哄煙 -->
-    <div class="table-operator">
-      <a-button @click="handleAdd" type="primary" icon="plus">鏂板</a-button>
-    </div>
+      <!-- 鎿嶄綔鎸夐挳鍖哄煙 -->
+      <div class="table-operator">
+        <a-button @click="handleAdd" type="primary" icon="plus">鏂板</a-button>
+      </div>
+    </template>
 
     <!-- table鍖哄煙-begin -->
     <a-table bordered rowKey="id" :columns="columns" :dataSource="dataSource" :pagination="ipagination"
              :scroll="{ x: 'max-content' }" :loading="loading" @change="handleTableChange">
+      <!--瀹夊叏瑁呯疆妫�鏌ョ粨鏋�-->
+      <template slot="safetyEquipmentCheckResult" slot-scope="text">
+        <a-switch checked-children="鏄�" un-checked-children="鍚�" :checked="Boolean(+text)" disabled/>
+      </template>
 
-        <span slot="action" slot-scope="text, record">
+      <!--绮惧害鍙傛暟妫�鏌ョ粨鏋�-->
+      <template slot="precisionCheckResult" slot-scope="text">
+        <a-switch checked-children="鏄�" un-checked-children="鍚�" :checked="Boolean(+text)" disabled/>
+      </template>
+
+      <!--鍔熻兘鐘舵�佹鏌ョ粨鏋�-->
+      <template slot="functionalCheckResult" slot-scope="text">
+        <a-switch v-if="text!=='NONE'" checked-children="鏄�" un-checked-children="鍚�" :checked="text==='YES'" disabled/>
+        <span v-else>鏃�</span>
+      </template>
+
+      <!--鍏朵粬妫�鏌ョ粨鏋�-->
+      <template slot="otherCheckResult" slot-scope="text">
+        <a-switch v-if="text!=='NONE'" checked-children="鏄�" un-checked-children="鍚�" :checked="text==='YES'" disabled/>
+        <span v-else>鏃�</span>
+      </template>
+
+      <!--璇曚欢妫�鏌ョ粨鏋�-->
+      <template slot="sampleCheckResult" slot-scope="text">
+        <a-switch checked-children="鏄�" un-checked-children="鍚�" :checked="Boolean(+text)" disabled/>
+      </template>
+
+      <span slot="action" slot-scope="text, record">
           <template v-if="record.evaluationStatus === 'WAIT_EVALUATION'">
-            <a-popconfirm title="纭畾棰嗗彇鍚楋紵"
-                          @confirm="handleReceive(record.id)">
+            <a-popconfirm title="纭畾棰嗗彇鍚楋紵" @confirm="handleReceive(record.id)">
             <a>棰嗗彇</a>
           </a-popconfirm>
 
            <a-divider type="vertical"/>
           </template>
 
-            <a @click="handleDetail(record)">璇︽儏</a>
+          <template v-if="record.evaluationStatus === 'WAIT_EVALUATION'||record.evaluationStatus==='LOCKED'">
+             <a @click="handleOrderChange(record)">鍙樻洿</a>
+
+             <a-divider type="vertical"/>
+          </template>
+
+          <a @click="handleDetail(record)" v-if="record.evaluationStatus!=='CHANGING'">璇︽儏</a>
         </span>
     </a-table>
     <!-- table鍖哄煙-end -->
 
-    <!-- 琛ㄥ崟鍖哄煙 -->
+    <!--宸ュ崟寮圭獥-->
     <eamTechnicalStatusEvaluationOrder-modal ref="modalForm" @ok="modalFormOk"/>
 
     <technical-status-evaluation-approval-modal ref="technicalStatusEvaluationApprovalModal"
-                                                :selectShenpiData="selectedOrderData"/>
+                                                :selectShenpiData="selectedRowData"/>
+
+    <!--宸ュ崟鍙樻洿寮圭獥-->
+    <eamTechnicalStatusEvaluationOrderChange-modal ref="orderChangeModal" @ok="modalFormOk"/>
   </a-card>
 </template>
 
 <script>
   import EamTechnicalStatusEvaluationOrderModal from './modules/EamTechnicalStatusEvaluationOrderModal'
+  import EamTechnicalStatusEvaluationOrderChangeModal from './modules/EamTechnicalStatusEvaluationOrderChangeModal'
   import { JeecgListMixin } from '@/mixins/JeecgListMixin'
   import { getAction } from '@/api/manage'
   import LxSearchEquipmentSelect from '../equipment/modules/LxSearchEquipmentSelect'
@@ -81,12 +118,20 @@
     components: {
       TechnicalStatusEvaluationApprovalModal,
       LxSearchEquipmentSelect,
-      EamTechnicalStatusEvaluationOrderModal
+      EamTechnicalStatusEvaluationOrderModal,
+      EamTechnicalStatusEvaluationOrderChangeModal
+    },
+    props: {
+      isDisplayOperation: {
+        type: Boolean,
+        default: true
+      }
     },
     data() {
       return {
         description: '鎶�鏈姸鎬侀壌瀹氬伐鍗曠鐞嗛〉闈�',
-        selectedOrderData: {},
+        disableMixinCreated: true,
+        selectedRowData: {},
         // 琛ㄥご
         columns: [
           {
@@ -116,6 +161,12 @@
             title: '璁惧鍨嬪彿',
             align: 'center',
             dataIndex: 'equipmentModel',
+            fixed: 'left'
+          },
+          {
+            title: '閴村畾鐘舵��',
+            align: 'center',
+            dataIndex: 'evaluationStatus_dictText',
             fixed: 'left'
           },
           {
@@ -154,11 +205,6 @@
             dataIndex: 'evaluator_dictText'
           },
           {
-            title: '閴村畾鐘舵��',
-            align: 'center',
-            dataIndex: 'evaluationStatus_dictText'
-          },
-          {
             title: '鍒涘缓鏂瑰紡',
             align: 'center',
             dataIndex: 'creationMethod_dictText'
@@ -166,42 +212,47 @@
           {
             title: '瀹夊叏瑁呯疆妫�鏌ョ粨鏋�',
             align: 'center',
-            dataIndex: 'safetyEquipmentCheckResult'
+            dataIndex: 'safetyEquipmentCheckResult',
+            scopedSlots: { customRender: 'safetyEquipmentCheckResult' }
           },
           {
             title: '绮惧害鍙傛暟妫�鏌ョ粨鏋�',
             align: 'center',
-            dataIndex: 'precisionCheckResult'
+            dataIndex: 'precisionCheckResult',
+            scopedSlots: { customRender: 'precisionCheckResult' }
           },
           {
             title: '鍔熻兘鐘舵�佹鏌ョ粨鏋�',
             align: 'center',
-            dataIndex: 'functionalCheckResult'
+            dataIndex: 'functionalCheckResult',
+            scopedSlots: { customRender: 'functionalCheckResult' }
           },
           {
             title: '鍏朵粬妫�鏌ョ粨鏋�',
             align: 'center',
-            dataIndex: 'otherCheckResult'
+            dataIndex: 'otherCheckResult',
+            scopedSlots: { customRender: 'otherCheckResult' }
           },
           {
             title: '缁翠慨瀹や富浠荤瀛�',
             align: 'center',
-            dataIndex: 'repairManagerSignature'
+            dataIndex: 'repairManagerSignature_dictText'
           },
           {
             title: '缁翠慨瀹や富浠荤瀛楁椂闂�',
             align: 'center',
-            dataIndex: 'repairManagerSignatureTime1'
+            dataIndex: 'repairManagerSignatureTime'
           },
           {
             title: '璇曚欢妫�鏌ョ粨鏋�',
             align: 'center',
-            dataIndex: 'sampleCheckResult'
+            dataIndex: 'sampleCheckResult',
+            scopedSlots: { customRender: 'sampleCheckResult' }
           },
           {
             title: '宸ヨ壓鍛樼瀛�',
             align: 'center',
-            dataIndex: 'processTechnicianSignature'
+            dataIndex: 'processTechnicianSignature_dictText'
           },
           {
             title: '宸ヨ壓鍛樼瀛楁椂闂�',
@@ -211,7 +262,7 @@
           {
             title: '閴村畾缁撴灉',
             align: 'center',
-            dataIndex: 'evaluationResult'
+            dataIndex: 'evaluationResult_dictText'
           },
           {
             title: '闄�/绂佺敤鍘熷洜',
@@ -221,7 +272,7 @@
           {
             title: '璁惧妫�鏌ヤ汉绛惧瓧',
             align: 'center',
-            dataIndex: 'inspectorSignature'
+            dataIndex: 'inspectorSignature_dictText'
           },
           {
             title: '璁惧妫�鏌ヤ汉绛惧瓧鏃堕棿',
@@ -247,13 +298,6 @@
             title: '闄勫綍D HF缂栫爜',
             align: 'center',
             dataIndex: 'hfCodeD'
-          },
-          {
-            title: '鎿嶄綔',
-            dataIndex: 'action',
-            align: 'center',
-            scopedSlots: { customRender: 'action' },
-            fixed: 'right'
           }
         ],
         url: {
@@ -262,7 +306,26 @@
         }
       }
     },
+    created() {
+      if (!this.isDisplayOperation) {
+        return
+      }
+      const operationColumn = {
+        title: '鎿嶄綔',
+        dataIndex: 'action',
+        align: 'center',
+        scopedSlots: { customRender: 'action' },
+        fixed: 'right',
+        width: 200
+      }
+      this.columns = [...this.columns, operationColumn]
+      this.loadData(1)
+    },
     methods: {
+      /**
+       * 鐐瑰嚮棰嗗彇鏃惰Е鍙�
+       * @param id
+       */
       handleReceive(id) {
         let that = this
         this.loading = true
@@ -284,11 +347,25 @@
           })
       },
 
+      /**
+       * 鐐瑰嚮鍙樻洿鏃惰Е鍙�
+       * @param record
+       */
+      handleOrderChange(record) {
+        this.$refs.orderChangeModal.title = '鍙樻洿'
+        this.$refs.orderChangeModal.add(record)
+      },
+
+      /**
+       * 鐐瑰嚮璇︽儏鏃惰Е鍙�
+       * @param record
+       */
       handleDetail(record) {
-        this.selectedOrderData = Object.assign({}, record)
-        this.$refs.technicalStatusEvaluationApprovalModal.recordDetail(record)
+        this.selectedRowData = Object.assign({}, record)
         this.$refs.technicalStatusEvaluationApprovalModal.title = '璇︽儏'
+        this.$refs.technicalStatusEvaluationApprovalModal.visible = true
         this.$refs.technicalStatusEvaluationApprovalModal.disableSubmit = true
+        this.$refs.technicalStatusEvaluationApprovalModal.handleDetail(record)
       }
     }
   }

--
Gitblit v1.9.3