From 1044e1ac72df8b8f01fba2dccf90e086b9734beb Mon Sep 17 00:00:00 2001 From: cks Date: Mon, 7 Feb 2022 16:00:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=A7=92=E8=89=B2=E4=B8=AD?= =?UTF-8?q?=E9=83=A8=E9=97=A8=E5=8F=8A=E4=BB=A5=E4=B8=8B=E6=9D=83=E9=99=90?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../module/system/service/permission/PermissionServiceImpl.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/yudao-module-system/yudao-module-system-impl/src/main/java/cn/iocoder/yudao/module/system/service/permission/PermissionServiceImpl.java b/yudao-module-system/yudao-module-system-impl/src/main/java/cn/iocoder/yudao/module/system/service/permission/PermissionServiceImpl.java index cb86bc7ad..864509f35 100644 --- a/yudao-module-system/yudao-module-system-impl/src/main/java/cn/iocoder/yudao/module/system/service/permission/PermissionServiceImpl.java +++ b/yudao-module-system/yudao-module-system-impl/src/main/java/cn/iocoder/yudao/module/system/service/permission/PermissionServiceImpl.java @@ -385,6 +385,8 @@ public class PermissionServiceImpl implements PermissionService { if (Objects.equals(role.getDataScope(), DataScopeEnum.DEPT_AND_CHILD.getScope())) { List depts = deptService.getDeptsByParentIdFromCache(loginUser.getDeptId(), true); CollUtil.addAll(result.getDeptIds(), CollectionUtils.convertList(depts, DeptDO::getId)); + //添加本身部门id + CollUtil.addAll(result.getDeptIds(), loginUser.getDeptId()); continue; } // 情况五,SELF