From dedbadd96ab7e1533572b25511fd201678c64dad Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期四, 17 十月 2024 09:56:18 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 Source/UBCS-WEB/src/components/Theme/DataAuthDialog.vue |   19 ++++++++++---------
 1 files changed, 10 insertions(+), 9 deletions(-)

diff --git a/Source/UBCS-WEB/src/components/Theme/DataAuthDialog.vue b/Source/UBCS-WEB/src/components/Theme/DataAuthDialog.vue
index d352de3..6961dfb 100644
--- a/Source/UBCS-WEB/src/components/Theme/DataAuthDialog.vue
+++ b/Source/UBCS-WEB/src/components/Theme/DataAuthDialog.vue
@@ -128,10 +128,8 @@
         this.loadAuthPage();
       }
     },
-    classifyAuthData(newval){
-
-      this.addIndex = newval.length <= 0 ? 0 :newval.length-1;
-      console.log(this.addIndex)
+    classifyAuthData(newval) {
+      this.addIndex = newval.length <= 0 ? 0 : newval.length - 1;
     }
   },
   computed: {},
@@ -173,13 +171,15 @@
 
         //鍜岃〃鏍煎垪杩涜瀵规瘮
         this.classifyAuthHeader.forEach((item) => {
+          // if (item.code !== 'data_view') {
+          //   this.$set(this.classifyAuthData[index].authButton, "allDisabled", true);
+          // }
           const isMatched = filteredItems.some((x) => x.id === item.prop);
           this.$nextTick(() => {
             if (this.classifyAuthData[index]) {
               if (isMatched) {
                 Object.keys(this.classifyAuthData[index]).forEach((key) => {
                   this.$set(this.classifyAuthData[index].authButton, item.code, true);
-
                   //娣诲姞 鈥滄煡鐪嬪叏閮ㄧ鐢ㄦ潯浠垛��
                   if (item.code === "data_view") {
                     this.$set(this.classifyAuthData[index].authButton, "allDisabled", true);
@@ -197,7 +197,7 @@
             }
           });
         });
-
+        // console.log(this.classifyAuthData)
         //寮哄埗鍒锋柊琛ㄦ牸
         this.itemKey = uuidv4();
       });
@@ -251,7 +251,7 @@
         classifyItem: this.classifyData.label,
         authButton: {},
         uuid: uuidv4(),//鐢熸垚鍞竴鐨刬d,
-        index: this.addIndex,
+        index: this.classifyAuthData.length -1,
       }
       //灏嗘寜閽缃繘鍘�
       this.classifyAuthButton.forEach(data => {
@@ -259,7 +259,7 @@
       })
       //console.log(item)
       this.classifyAuthData.push(item)
-      this.roleHandlerMethods(this.roleList[0].id, 'add', this.addIndex)
+      this.roleHandlerMethods(this.roleList[0].id, 'add', this.classifyAuthData.length -1)
     },
     // 鍒犻櫎琛�
     subClassifyAuth() {
@@ -289,6 +289,7 @@
         classifyAuthList: [],
         isCLear: false, //榛樿鏄竻绌�
         classifyId: this.TreeNode.oid,
+        authType: 'data_auth',
       };
       let isRepeat = false;
       if (this.classifyAuthData.length > 0) {
@@ -314,7 +315,7 @@
           let itemButtonList = [];
           //绛涢�夊嚭鎸夐挳鍕鹃�変负true鐨勫垪
           for (let key in item) {
-            if (item[key] === true) {
+            if (item[key] === true && key !== 'checkTheStatus') {
               itemButtonList.push(key);
             }
           }

--
Gitblit v1.9.3