From d186b4d37394e4816e0f271fcced4d06b3069454 Mon Sep 17 00:00:00 2001
From: 田源 <lastanimals@163.com>
Date: 星期一, 16 十二月 2024 15:31:28 +0800
Subject: [PATCH] 路由query添加当前页面id&&人员组织管理模块下所有页面按钮权限控制

---
 Source/plt-web/plt-web-ui/src/store/modules/user.js |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/Source/plt-web/plt-web-ui/src/store/modules/user.js b/Source/plt-web/plt-web-ui/src/store/modules/user.js
index da2ef54..8e1fbc3 100644
--- a/Source/plt-web/plt-web-ui/src/store/modules/user.js
+++ b/Source/plt-web/plt-web-ui/src/store/modules/user.js
@@ -17,7 +17,7 @@
     label: propsConfig.label || 'name',
     path: propsConfig.path || 'path',
     icon: propsConfig.icon || 'icon',
-    children: propsConfig.children || 'children'
+    children: propsConfig.children || 'children',
   }
   const icon = ele[propsDefault.icon];
   ele[propsDefault.icon] = validatenull(icon) ? menu.iconDefault : icon;
@@ -232,7 +232,7 @@
 
           commit('SET_MENU_ALL', menu)
           commit('SET_MENU', menu)
-          //dispatch('GetButtons');s
+          dispatch('GetButtons');
           resolve(menu)
         })
       })
@@ -244,6 +244,7 @@
       return new Promise((resolve) => {
         getButtons().then(res => {
           const data = res.data.data;
+          console.log('getButton',data)
           commit('SET_PERMISSION', data);
           resolve();
         })
@@ -305,7 +306,7 @@
             Vue.set(children, child.code, true);
           });
         }
-        Vue.set(permission_new, item.code, children);
+        Vue.set(permission_new, item.id, children);
       });
       state.permission = permission_new;
       setStore({name: "permission", content: permission_new});

--
Gitblit v1.9.3