From 7577e0d40354021d70b78d58b712ff8c2e8ad485 Mon Sep 17 00:00:00 2001 From: ludc <ludc@vci-tech.com> Date: 星期五, 03 一月 2025 10:47:33 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- Source/plt-web/plt-web-ui/src/store/modules/user.js | 13 +++++++------ 1 files changed, 7 insertions(+), 6 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 e6e7fba..3a33a35 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 @@ -16,8 +16,8 @@ const propsDefault = { label: propsConfig.label || 'name', path: propsConfig.path || 'path', - icon: propsConfig.icon || 'icon', - children: propsConfig.children || 'children' + icon: propsConfig.icon || 'source', + children: propsConfig.children || 'children', } const icon = ele[propsDefault.icon]; ele[propsDefault.icon] = validatenull(icon) ? menu.iconDefault : icon; @@ -36,7 +36,7 @@ function updateCode(items) { items.forEach(item => { item.pathValue = item.path; - item.path = '/' + item.code; + item.path = '/' + item.id; item.query = {}; // 鍒濆鍖� item.query if (item.pathValue.indexOf('?') != -1) { item.query = queryStringToObject(item.pathValue) @@ -66,7 +66,7 @@ let passwordDes = func.encryptData(userInfo.password, 'daliantan0v0vcip') loginByUsername(userInfo.deptId, userInfo.roleId, userInfo.username, passwordDes, userInfo.type, userInfo.key,).then(res => { const data = res.data; - if (data.obj.failCode === 'loginSuccess') { + if (data.obj.failCode === 'loginSuccess' || data.obj.failCode === 'passwordRemainDay') { commit('SET_TOKEN', data.obj.tokenVO.accessToken); commit('SET_REFRESH_TOKEN', data.obj.tokenVO.accessToken); commit('DEL_ALL_TAG'); @@ -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