From d338b50afd6504a9676f0a26b3ecbcc844483e7c Mon Sep 17 00:00:00 2001 From: 潘志宝 <979469083@qq.com> Date: 星期四, 21 十一月 2024 08:57:08 +0800 Subject: [PATCH] 并发采集 --- iailab-module-system/iailab-module-system-biz/src/main/java/com/iailab/module/system/service/permission/MenuServiceImpl.java | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/iailab-module-system/iailab-module-system-biz/src/main/java/com/iailab/module/system/service/permission/MenuServiceImpl.java b/iailab-module-system/iailab-module-system-biz/src/main/java/com/iailab/module/system/service/permission/MenuServiceImpl.java index d3c0c46..1497663 100644 --- a/iailab-module-system/iailab-module-system-biz/src/main/java/com/iailab/module/system/service/permission/MenuServiceImpl.java +++ b/iailab-module-system/iailab-module-system-biz/src/main/java/com/iailab/module/system/service/permission/MenuServiceImpl.java @@ -158,8 +158,10 @@ @Override public List<MenuDO> getAppMenuListByTenant(MenuListReqVO reqVO) { + // 获取 tenantId + Long tenantId = getTenantId(); // 查询所有菜单,并过滤掉关闭的节点 - List<MenuDO> menus = getAppMenuList(reqVO); + List<MenuDO> menus = getAppMenuList(tenantId, reqVO); // 开启多租户的情况下,需要过滤掉未开通的菜单 tenantService.handleTenantMenu(menuIds -> menus.removeIf(menu -> !CollUtil.contains(menuIds, menu.getId()))); return menus; @@ -215,9 +217,7 @@ } @Override - public List<MenuDO> getAppMenuList(MenuListReqVO reqVO) { - // 获取 tenantId - Long tenantId = getTenantId(); + public List<MenuDO> getAppMenuList(Long tenantId, MenuListReqVO reqVO) { List<MenuDO> menuDOS = menuMapper.selectAppMenuList(tenantId, reqVO); Set<Long> menuDOIds = menuDOS.stream().map(MenuDO::getId).collect(Collectors.toSet()); // 获得角色列表 -- Gitblit v1.9.3