From 4d15b0b7853292b3f2a80a23af19955375f12e80 Mon Sep 17 00:00:00 2001
From: fujunling <2984387807@qq.com>
Date: 星期二, 20 六月 2023 11:09:39 +0800
Subject: [PATCH] Merge branch 'master' of http://dev.vci-tech.com:1065/r/ubcs

---
 Source/UBCS-WEB/src/components/Crud/VciMasterCrud.vue |  104 +++++++++++++++++++++++++++------------------------
 1 files changed, 55 insertions(+), 49 deletions(-)

diff --git a/Source/UBCS-WEB/src/components/Crud/Crud.vue b/Source/UBCS-WEB/src/components/Crud/VciMasterCrud.vue
similarity index 87%
rename from Source/UBCS-WEB/src/components/Crud/Crud.vue
rename to Source/UBCS-WEB/src/components/Crud/VciMasterCrud.vue
index 53cd177..b17dbae 100644
--- a/Source/UBCS-WEB/src/components/Crud/Crud.vue
+++ b/Source/UBCS-WEB/src/components/Crud/VciMasterCrud.vue
@@ -9,8 +9,9 @@
           :codeRuleOid="this.codeRuleOid"
           :disabledProp="disabledProp"
           :templateOid="templateOid"
-          :type="add"
+          type="add"
           :visible.sync="addvisible"
+          @submit="AddSumbit"
         >
         </FormTemplateDialog>
         <el-button plain size="small" type="primary" @click="editHandler">缂栬緫
@@ -21,9 +22,10 @@
           :disabledProp="disabledProp"
           :rowOid="rowOid"
           :templateOid="templateOid"
-          :type="edit"
+          type="edit"
           :title="'淇敼缂栫爜淇℃伅'"
           :visible.sync="editvisible"
+          @submit="EditSumbit"
         ></FormTemplateDialog>
         <el-button plain size="small" type="primary">鎵归噺瀵煎叆鐢宠</el-button>
         <el-button plain size="small" type="primary">鍘嗗彶鏁版嵁瀵煎叆</el-button>
@@ -33,7 +35,7 @@
         <el-button plain size="small" type="primary">鍒犻櫎</el-button>
         <el-button plain size="small" type="primary" @click="setHandler">鍙戝竷</el-button>
         <set-personnel :visible.sync="visibleFlow"  :parameter="parameter"
-                       type="PUBLIC"></set-personnel>
+        ></set-personnel>
         <el-button plain size="small" type="primary" @click="DataChange">鏁版嵁鏇存敼</el-button>
         <FormTemplateDialog
           :codeClassifyOid="this.codeClassifyOid"
@@ -54,14 +56,21 @@
           <advanced-query :options="this.options" :visible.sync="findvisible"
                           @echoContion="echoContion"></advanced-query>
         </el-button>
-        <el-button plain size="small" type="primary">鐩镐技椤规煡璇�</el-button>
+        <el-button plain size="small" type="primary" @click="similarHandler">鐩镐技椤规煡璇�</el-button>
+        <ResembleQueryDialog
+          :visible.sync="similarVisible"
+          :templateOid="templateOid"
+          :codeClassifyOid="codeClassifyOid"
+          :rowOid="rowOid"
+          :codeRuleOid="this.codeRuleOid"
+        ></ResembleQueryDialog>
         <el-button plain size="small" style="margin-left: 1px;margin-top:10px" type="primary">鍒锋柊</el-button>
         <el-input placeholder="璇疯緭鍏ュ叧閿瓧鎸夊洖杞︽煡璇�" size="small"
                   style="width: 180px;margin-left: 5px;margin-top:10px"></el-input>
       </div>
       <el-row style="height: 700px;width: 100%">
         <el-table v-loading="isLoading" :data="tableData" max-height="700" style="" @cell-click="handleCellClick"
-                  @selection-change="handleSelectionChange" @sort-change="sortChange">
+                  @selection-change="handleSelectionChange" @sort-change="sortChange" v-if="tableData.length != 0">
           <el-table-column
             fixed
             type="selection"
@@ -109,11 +118,12 @@
 import {listCodeAttributeByClassId} from '@/api/integration/integration.js'
 import integrationTransfer from '@/views/integration/integrationTransfer'
 import SetPersonnel from '@/components/template/SetPersonnel'
-
+import ResembleQueryDialog from "@/components/FormTemplate/ResembleQueryDialog.vue";
 export default {
   components: {
     integrationTransfer,
-    SetPersonnel
+    SetPersonnel,
+    ResembleQueryDialog
   },
   name: "Crud.vue",
   props: {
@@ -154,12 +164,13 @@
   },
   data() {
     return {
+      //鐩镐技椤规煡璇�
+      similarVisible:false,
       //鍙戝竷
       parameter:{
         ids:['0000','22222222'],
-        code:'8b5e2017-990f-454a-9c39-4c4eeeb57553',
+        code:this.templateOid,
         type:'PUBLIC',
-        name:'妯℃澘name',
         template:'妯℃澘template'
       },
       visibleFlow: false,
@@ -215,7 +226,7 @@
     codeClassifyOid: {
       handler(newval, oldval) {
         this.codeClassifyOid = newval;
-        this.CrudHeaderRend()
+
       },
       deep: true
     },
@@ -234,32 +245,13 @@
         this.page.total = newval;
       }
     },
-    // tableHeadDataFateher: {
-    //   handler(newval, oldval) {
-    //     let List = newval.tableDefineVO.cols[0];
-    //     List.forEach(item => {
-    //       let columnItem = {
-    //         label: item.title,
-    //         prop: item.field,
-    //         type: this.columnType[item.type],
-    //         sortable: item.sort,
-    //         width: item.minWidth
-    //       };
-    //       this.tableHeadData.push(columnItem);
-    //       console.log('table',this.tableHeadData)
-    //     })
-    //   }
-    // }
   },
   methods: {
     setHandler() {
-      this.visibleFlow = true
+      this.visibleFlow = true;
     },
     huishouHandler() {
-      console.log('tem', this.templateOid)
-      console.log('table', this.tableData)
-      console.log('tabheadle', this.tableHeadData)
-      console.log('tableFather', this.tableHeadDataFateher)
+
     },
     openD() {
       this.dialogPush = true;
@@ -311,21 +303,6 @@
       this.$nextTick(() => {
         this.$refs.crud.doLayout();
       });
-    },
-    tableHeadHandle() {
-      this.options = this.tableHeadDataFateher.tableDefineVO.seniorQueryColumns
-      this.List = this.tableHeadDataFateher.tableDefineVO.cols[0];
-      this.List.forEach(item => {
-        let columnItem = {
-          label: item.title,
-          prop: item.field,
-          type: this.columnType[item.type],
-          sortable: item.sort,
-          width: item.minWidth
-        };
-        this.option.column.push(columnItem);
-        this.option.column = this.tableHeadData;
-      })
     },
     //琛ㄦ牸澶存覆鏌�
     CrudHeaderRend() {
@@ -402,12 +379,20 @@
     },
     //澶氶��
     handleSelectionChange(row) {
+      if(this.row){
+        this.rowOid = row[0].oid;
+      }else {
+        this.rowOid=''
+      }
+      this.selectRow = row;
       console.log(row)
-      this.rowOid = row.oid
-      this.selectRow = row
     },
     //缂栬緫
     editHandler() {
+      console.log('row',this.rowOid)
+      console.log('temp',this.templateOid)
+      console.log('code',this.codeClassifyOid)
+      console.log('rule',this.coderuleoid)
       if (this.selectRow.length <= 0) {
         this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�')
       } else if (this.selectRow.length > 1) {
@@ -420,7 +405,8 @@
     },
     //楂樼骇鏌ヨ鎸夐挳
     findHandler(){
-      this.findvisible=true
+      this.findvisible=true;
+      console.log(this.options)
     },
     // 楂樼骇鏌ヨ
     echoContion(val) {
@@ -431,6 +417,17 @@
       }).then(res=>{
         console.log(res)
       })
+    },
+    //鐩镐技椤规煡璇�
+    similarHandler(){
+      if (this.selectRow.length <= 0) {
+        this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�')
+      } else if (this.selectRow.length > 1) {
+        this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�')
+      }  else {
+        this.similarVisible=true;
+      }
+
     },
     //鏁版嵁鏇存敼
     DataChange(){
@@ -443,6 +440,15 @@
       } else {
         this.DataVisible = true
       }
+    },
+    //澧炲姞淇濆瓨
+    AddSumbit(val){
+      console.log(val)
+      this.addvisible=false
+    },
+    EditSumbit(val){
+      console.log(val)
+      this.editvisible=false
     }
   }
 }

--
Gitblit v1.9.3