From 42c17fe468ceea7e5eed7fec520b9858bed02e85 Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期五, 04 八月 2023 17:52:30 +0800
Subject: [PATCH] Merge branch 'master' of http://dev.vci-tech.com:1065/r/ubcs

---
 Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue |   31 ++++++++++++++++++++++++-------
 1 files changed, 24 insertions(+), 7 deletions(-)

diff --git a/Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue b/Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue
index cc7c67f..d7adab9 100644
--- a/Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue
+++ b/Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue
@@ -67,7 +67,7 @@
                               :disabledProp="disabledProp" :rowOid="rowOid" :templateOid="templateOid"
                               :title="'宸插彂甯冩暟鎹洿鏀�'"
                               type="edit"
-                              :visible.sync="DataVisible"></FormTemplateDialog>
+                              :visible.sync="DataVisible" @submit="updataSumbit"></FormTemplateDialog>
           <!--          鍙戝竷-->
           <set-personnel :parameter="this.parameter" :title="title" :visible.sync="visibleFlow"
                          @onLoad="onLoad"></set-personnel>
@@ -116,7 +116,7 @@
   </basic-container>
 </template>
 <script>
-import {MasterTable, TableData, FindData, addSaveCode, editSaveCode, deleteCode} from "@/api/GetItem";
+import {MasterTable, TableData, FindData, addSaveCode, editSaveCode, deleteCode, upSaveCode} from "@/api/GetItem";
 import {processTS, changeStatus} from "@/api/template/setPersonnel"
 import {listCodeAttributeByClassId} from "@/api/integration/integration.js";
 import integrationTransfer from "@/views/integration/integrationTransfer";
@@ -300,8 +300,6 @@
     },
     tableDataArray: {
       handler(newval, oldval) {
-        this.keyWordFind='';
-        this.WupinFindValue=''
         this.tableData = newval;
         this.searchResults = newval
         this.doLayout()
@@ -323,8 +321,13 @@
               }
             }
           }
+
+          if(_index==0){
+            this.keyWordFind=record.field
+          }
         })
         this.tableHeadFindDatas = newval;
+        this.WupinFindValue=''
       },
     },
     total: {
@@ -849,6 +852,7 @@
         this.$message.warning("鍙湁鐘舵�佷负宸插彂甯冪殑鏁版嵁鎵嶈兘杩涜鏁版嵁鏇存敼");
       } else {
         this.DataVisible = true;
+        this.rowOid = this.selectRow[0]['oid']
       }
     },
     //澧炲姞淇濆瓨
@@ -860,9 +864,23 @@
         })
       })
     },
+    //淇敼鍥炶皟
     EditSumbit(val) {
       this.editvisible = false;
       editSaveCode(val).then(res => {
+        this.$nextTick(() => {
+          this.onLoad()
+        })
+      })
+    },
+    //鏁版嵁鏇存敼鍥炶皟
+    updataSumbit(val){
+      this.DataVisible = false;
+      val.copyfromversion = this.rowOid;
+      val.oid=''
+      console.log(val)
+      upSaveCode(val).then(res=>{
+        console.log(res)
         this.$nextTick(() => {
           this.onLoad()
         })
@@ -875,10 +893,10 @@
     },
     //杈撳叆鍥炶溅鎼滅储
     tableFindInp() {
-      if (this.WupinFindValue.trim() === '') {
+      /*if (this.WupinFindValue.trim() === '') {
         this.$message.warning('杈撳叆鍊间笉鑳戒负绌�')
         return;
-      }
+      }*/
       TableData({
         templateOid: this.templateOid,
         codeClassifyOid: this.codeClassifyOid,
@@ -886,7 +904,6 @@
         limit: this.page.pageSize,
         [ 'conditionMap[' + this.keyWordFind + ']']: '*' + this.WupinFindValue + '*'
       }).then(res => {
-        console.log(res)
         this.tableData = res.data.data
       })
     }

--
Gitblit v1.9.3