From 729b698b17d7468acbc6c495746a72c9150fdaeb Mon Sep 17 00:00:00 2001
From: yangys <y_ys79@sina.com>
Date: 星期二, 09 九月 2025 11:49:47 +0800
Subject: [PATCH] 按钮改名下传

---
 src/views/flowmgr/taskassigntemp.vue |   43 +++++++++++++++++++++++++++++++++++++++----
 1 files changed, 39 insertions(+), 4 deletions(-)

diff --git a/src/views/flowmgr/taskassigntemp.vue b/src/views/flowmgr/taskassigntemp.vue
index 996860e..8cbc96c 100644
--- a/src/views/flowmgr/taskassigntemp.vue
+++ b/src/views/flowmgr/taskassigntemp.vue
@@ -15,14 +15,18 @@
           :data="treeData" :props="defaultProps">
           </el-tree-select>
       </template>
+      <template #drawingNo="{}">
+        <el-autocomplete   v-model="attachForm.drawingNo"
+        :fetch-suggestions="querySearchAsync"
+        :trigger-on-focus="false" @select="handleSelect"
+          >
+        </el-autocomplete>
+      </template>
     </avue-form>
   </basic-container>
 </template>
 
 <script>
-import {
-  getQueryString,
-} from '@/utils/util';
 
 export default {
   watch: {
@@ -56,6 +60,7 @@
         disabled: (data) => data.nodeType!=='machine',//浠呮満搴婅妭鐐瑰彲閫�
         isLeaf: (data) => !data.hasChildren
       },
+      timeout:0, //闆朵欢鍙峰姞杞界殑timeout
       machineCodeList: [],
       attachOption: {
         labelWidth: 160,
@@ -87,7 +92,7 @@
             },
           },
           {
-            label: '鍥惧彿鐗堟',
+            label: '鍥剧焊鐗堟',
             prop: 'drawingNoEdition',
             type: 'input',
             span: 12,
@@ -246,6 +251,36 @@
       // 濡傛灉鏃笉鏄痬achine鑺傜偣涔熸病鏈夊瓙鑺傜偣锛岀洿鎺ヨ繑鍥炲師鑺傜偣
       return node;
     },
+    querySearchAsync(query, cb) {//闆剁粍浠跺彿鎼滅储寤鸿
+
+      axios({
+        url: '/blade-mdm/producedivision/select-data',
+        method: 'get',
+        params: {drawingNo: query},
+      }).then(
+        res => {
+          if(res.data.code == 200){
+            let list = res.data.data;
+            for(let i of list){
+              i.value = i.ljh;
+            }
+
+            clearTimeout(this.timeout)
+            this.timeout = setTimeout(() => {
+              cb(list);
+            }, 1000)
+            
+          }
+        },
+        error => {
+          console.log(error);
+        }
+      );
+      
+    },
+    handleSelect(item) {
+      this.attachForm.productModel = item.cph;
+    },
     handleTrim(col){
       //console.log(col)
       let value = this.attachForm[col.column.prop];

--
Gitblit v1.9.3