From c6e96cdb8b1cfb51e9a45bf86c38d1353e983127 Mon Sep 17 00:00:00 2001
From: 吴羡 <16976746+Xian-TT3@user.noreply.gitee.com>
Date: 星期一, 19 十月 2026 15:19:48 +0800
Subject: [PATCH] 设备模块业务完善及前序页面优化

---
 src/views/CNAS/resourceDemand/device/component/quantityValueTraceabilityPlan.vue |   26 ++++++++------------------
 1 files changed, 8 insertions(+), 18 deletions(-)

diff --git a/src/views/CNAS/resourceDemand/device/component/quantityValueTraceabilityPlan.vue b/src/views/CNAS/resourceDemand/device/component/quantityValueTraceabilityPlan.vue
index 1ce5c03..fd36b81 100644
--- a/src/views/CNAS/resourceDemand/device/component/quantityValueTraceabilityPlan.vue
+++ b/src/views/CNAS/resourceDemand/device/component/quantityValueTraceabilityPlan.vue
@@ -15,7 +15,8 @@
           <el-table-column label="骞翠唤" min-width="80" prop="planYear"></el-table-column>
           <el-table-column label="鏂囦欢鍚嶇О" min-width="120" prop="compiler"></el-table-column>
           <el-table-column label="缂栧埗浜�" min-width="150" prop="compiler"></el-table-column>
-          <el-table-column label="缂栧埗鏃堕棿" min-width="160" prop="datePreparation"></el-table-column>
+          <el-table-column label="缂栧埗鏃堕棿" min-width="160" prop="datePreparation"
+            :formatter="formatDateCell"></el-table-column>
           <el-table-column label="鎵瑰噯浜�" min-width="180" prop="audit"></el-table-column>
           <el-table-column label="鎵瑰噯鐘舵��" min-width="180" prop="status">
             <template #default="scope">
@@ -23,7 +24,8 @@
               <el-tag v-if="scope.row.status === 0" type="danger">涓嶆壒鍑�</el-tag>
             </template>
           </el-table-column>
-          <el-table-column label="鎵瑰噯鏃堕棿" min-width="180" prop="auditDate"></el-table-column>
+          <el-table-column label="鎵瑰噯鏃堕棿" min-width="180" prop="auditDate"
+            :formatter="formatDateCell"></el-table-column>
           <!-- 鎿嶄綔鎸夐挳 -->
           <el-table-column align="center" fixed="right" label="鎿嶄綔" min-width="270">
             <template #default="scope">
@@ -174,12 +176,11 @@
 } from '@/api/cnas/resourceDemand/device.js'
 import { selectUserCondition } from "@/api/business/inspectionTask";
 import { mapGetters } from "@/utils/store-compat";
-import draftSave from '@/mixins/draftSave'
+import { formatListDate } from './dateFormat'
 export default {
   name: "quantity-value-traceability-plan",
   // import 寮曞叆鐨勭粍浠堕渶瑕佹敞鍏ュ埌瀵硅薄涓墠鑳戒娇鐢�
   components: {},
-  mixins: [draftSave],
   props: {
     clickNodeVal: {
       type: Object,
@@ -222,6 +223,9 @@
   },
   // 鏂规硶闆嗗悎
   methods: {
+    formatDateCell(row, column, cellValue) {
+      return formatListDate(cellValue)
+    },
     // 鏌ヨ
     getYearTableDetailData() {
       this.yearTableDetailDataLoading = true
@@ -286,21 +290,11 @@
           if (res.code === 200) {
             this.form = res.data
             this.deviceTraceabilityManagementDetails = this.form.deviceTraceabilityManagementDetails
-            this.restoreTraceabilityDraft()
           }
         }).catch(error => {
           console.error(error)
           this.yearTableLoading = false
         })
-      } else {
-        this.restoreTraceabilityDraft()
-      }
-    },
-    restoreTraceabilityDraft() {
-      if (this.operationType === 'add' || this.operationType === 'edit') {
-        const rid = this.operationType === 'edit' ? this.traceabilityManagementId : ''
-        this.draftRestore('traceabilityForm', 'form', rid, 'applicationForm')
-        this.draftRestore('traceabilityRows', 'deviceTraceabilityManagementDetails', rid, 'applicationForm')
       }
     },
     // 娣诲姞璁惧
@@ -361,8 +355,6 @@
         addTraceabilityManagement(this.form).then(res => {
           if (res.code == 200) {
             this.$message.success('鏂板鎴愬姛')
-            this.draftClear('traceabilityForm')
-            this.draftClear('traceabilityRows')
             this.applicationForm = false
             this.getYearTableDetailData()
           }
@@ -374,8 +366,6 @@
         updateTraceabilityManagement(this.form).then(res => {
           if (res.code == 200) {
             this.$message.success('淇敼鎴愬姛')
-            this.draftClear('traceabilityForm')
-            this.draftClear('traceabilityRows')
             this.applicationForm = false
             this.getYearTableDetailData()
           }

--
Gitblit v1.9.3