From c92ad78d3cfa50dce52d210bf33728a85d23addc Mon Sep 17 00:00:00 2001
From: rain <1679827795@qq.com>
Date: Mon, 28 Apr 2025 15:02:02 +0800
Subject: [PATCH] 工单类型修改

---
 src/views/tickets/ticket.vue |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/views/tickets/ticket.vue b/src/views/tickets/ticket.vue
index 5dcc0d3..02b0592 100644
--- a/src/views/tickets/ticket.vue
+++ b/src/views/tickets/ticket.vue
@@ -983,7 +983,7 @@
             startTime: item.create_time,
             aiType: item.ai_types,
             content: item.content, // 将后端返回的 content 映射为 content
-            type: this.types.find(t => t.value === item.event_dict_key)?.label,
+            type: this.types.find(t => t.value === item.work_order_type_dict_key)?.label,
             keyData: (!isNaN(longitude) && !isNaN(latitude))
               ? `${longitude.toFixed(6)}, ${latitude.toFixed(6)}`
               : '未知位置',
@@ -1048,7 +1048,7 @@
           longitude: String(this.form.location[0]),
           latitude: String(this.form.location[1]),
           address: this.form.address,
-          eventDictKey: this.form.type,
+          workOrderTypeDictKey: this.form.type,
           aiType: Array.isArray(this.form.algorithm) ? this.form.algorithm : [this.form.algorithm], // 传数组
           updateUser: this.form.handler,
           createDept: this.form.department,
@@ -1102,7 +1102,7 @@
           longitude: this.form.location?.[0] ? String(this.form.location[0]) : undefined,
           latitude: this.form.location?.[1] ? String(this.form.location[1]) : undefined,
           address: this.form.address || undefined,
-          eventDictKey: this.form.type || undefined,
+          workOrderTypeDictKey: this.form.type || undefined,
           aiType: Array.isArray(this.form.algorithm) ? this.form.algorithm : [this.form.algorithm], // 传数组
           updateUser: handlerValue,
           createDept: this.form.department || undefined,
@@ -1464,7 +1464,7 @@
               发起时间: item.create_time || '',
               关联算法: item.ai_types || '',
               工单内容: item.address || '',
-              工单类型: this.types.find(t => t.value === item.event_dict_key)?.label || '',
+              工单类型: this.types.find(t => t.value === item.work_order_type_dict_key)?.label || '',
               经纬度: (!isNaN(longitude) && !isNaN(latitude)) ? `${longitude.toFixed(6)}, ${latitude.toFixed(6)}` : '',
               创建人: item.create_user || '',
               处理人: item.update_user || '',
@@ -1806,7 +1806,7 @@
       }
 
       // 获取工单类型值 - 从types中找到匹配的值
-      const typeValue = this.types.find(t => t.label === row.type)?.value || row.event_dict_key;
+      const typeValue = this.types.find(t => t.label === row.type)?.value || row.work_order_type_dict_key;
 
       // 获取处理人ID - 使用userNameToIdMap映射
       const handlerId = this.userNameToIdMap[row.handler] || row.handler;

--
Gitblit v1.9.3