From fbcf5ee613da2bb6426ae53cb965a0f7260c01f0 Mon Sep 17 00:00:00 2001
From: 田源 <lastanimals@163.com>
Date: 星期一, 31 七月 2023 14:49:29 +0800
Subject: [PATCH] 全屏编辑编辑bug

---
 Source/UBCS-WEB/src/components/Theme/ThemeAttrCrud.vue |   28 ++++++++++++++++++----------
 1 files changed, 18 insertions(+), 10 deletions(-)

diff --git a/Source/UBCS-WEB/src/components/Theme/ThemeAttrCrud.vue b/Source/UBCS-WEB/src/components/Theme/ThemeAttrCrud.vue
index 2adc176..5fdbfbf 100644
--- a/Source/UBCS-WEB/src/components/Theme/ThemeAttrCrud.vue
+++ b/Source/UBCS-WEB/src/components/Theme/ThemeAttrCrud.vue
@@ -45,7 +45,7 @@
       </el-button-group>
       <!-- 鏄惁寮�鍚紪杈�     -->
     <el-button-group>
-      <el-button size="small" plain  icon="el-icon-view"  v-if="(!checkStatus|| crudLCStatus=='Editing') && !editOpenFlag" @click="editOpen" >寮�鍚紪杈�</el-button>
+      <el-button size="small" plain  icon="el-icon-view"  v-if="(!checkStatus|| crudLCStatus=='Editing') && !editOpenFlag && attrEditVisible == false && attrFlagChiledren==false" @click="editOpen" >寮�鍚紪杈�</el-button>
     </el-button-group>
     </div>
 <!--    寮圭獥-->
@@ -207,7 +207,7 @@
       </el-dialog>
       <!--        鍏ㄥ睆缂栬緫-->
       <el-dialog :visible.sync="attrEditVisible" append-to-body fullscreen="true">
-        <attrCrud :ProData="this.ProData" :attrFlagChiledren="this.attrFlag" :crudArrayFlag="this.crudArrayFlag"></attrCrud>
+        <attrCrud :ProData="this.ProData" :attrFlagChiledren="this.attrFlag" :editOpenFlag="editOpenFlag" :crudArrayFlag="this.crudArrayFlag"></attrCrud>
       </el-dialog>
       <!--      缁勫悎瑙勫垯-->
       <formula-editor :systemVariableTableData="systemVariableTableData"
@@ -251,7 +251,7 @@
     </div>
     <el-table :data="ProData"
               style="width: 100%"
-              height="400"
+              :height="this.editStyleFlag ? 450 : 900"
               @cell-click="handleCellClicks"
               @select="selectHandle"
               @selection-change="selectionChange"
@@ -409,6 +409,8 @@
   },
   data() {
     return {
+      //鍏ㄥ睆缂栬緫楂樺害鐘舵��
+      edittStyleFlag:false,
       loading:false,
       referConfigText:"",
       referConfigVisble:false,
@@ -1466,11 +1468,14 @@
     //灞炴�у垎缁勬彁浜�
     attrHandle() {
       console.log(this.attrSelectList)
-      // this.$set(this.attrRow, 'attributeGroup', this.attrModel)
-      // this.attrSelectList.attributeGroup=this.attrModel
       this.attrSelectList.forEach(item=>{
         item.attributeGroup=this.attrModel
       })
+      if(this.CurrentCell){
+        this.$set(this.CurrentCell, 'attributeGroup', this.attrModel)
+      }else {
+        this.$set(this.attrSelectList[0], 'attributeGroup', this.attrModel)
+      }
       this.attrModel = "";
       this.attrVisible = false;
     },
@@ -1610,6 +1615,9 @@
     addsHandler() {
       batchAddSave(JSON.parse(JSON.stringify(this.ProData))).then(res => {
         this.$message.success('淇濆瓨鎴愬姛')
+        this.editOpenFlag=false
+      }).catch(()=>{
+        this.$message.warning('淇濆瓨澶辫触锛岃鏌ョ湅鎺у埗鍙拌緭鍑猴紒')
       })
     },
 
@@ -1657,8 +1665,8 @@
          }else if(column.property == 'verifyRule'){
            this.RulesForm.expressionTextt=this.CurrentCell.verifyRule;
            this.rulesVisible=true;
-           console.log(this.CurrentCell.verifyRule)
-           console.log(this.RulesForm.expressionText)
+         }else if(column.property == 'attributeGroup'){
+           this.attrVisible = true;
          }
        }
     },
@@ -1893,6 +1901,8 @@
       if (this.crudArray.length < 1) {
         this.$message.warning('璇烽�夋嫨涓�涓ā鏉�')
       } else {
+        this.editStyleFlag=!this.editStyleFlag;
+        // this.editOpenFlag=true;
         this.attrEditVisible = true;
         this.attrFlag = true;
       }
@@ -1925,11 +1935,9 @@
     sortChange(val) {
       console.log(val)
     },
+    //寮�鍚紪杈�
     editOpen(){
       this.editOpenFlag=true;
-      console.log('涓嶇瓑浜�',this.checkStatus)
-      console.log('绛変簬',this.editOpenFlag)
-      console.log('绛変簬',this.crudLCStatus)
     }
   }
 }

--
Gitblit v1.9.3