lipenghui há 3 meses atrás
pai
commit
7429a928a3

+ 3 - 0
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/user/AdminUserServiceImpl.java

@@ -99,6 +99,7 @@ public class AdminUserServiceImpl implements AdminUserService {
     public List<Pms.deptStat> selectCountByDeptId(Long deptId) {
         DeptDO rh = deptMapper.selectOne("name", "瑞恒兴域");
         Set<Long> childDeptIdListFromCache = deptService.getChildDeptIdListFromCache(rh.getId());
+        childDeptIdListFromCache.add(rh.getId());
         UserPageReqVO pageReqVO = new UserPageReqVO();
         Long rhtotal = userMapper.selectCountByDeptIds(childDeptIdListFromCache, pageReqVO);
         ImmutableMap<String, LocalDateTime> beginEndWeek = DateUtils.getBeginEndWeek();
@@ -108,6 +109,7 @@ public class AdminUserServiceImpl implements AdminUserService {
 
         DeptDO ry = deptMapper.selectOne("name", "瑞鹰国际");
         Set<Long> rydepts = deptService.getChildDeptIdListFromCache(ry.getId());
+        rydepts.add(ry.getId());
         UserPageReqVO pageReqVO1 = new UserPageReqVO();
         Long rytotal = userMapper.selectCountByDeptIds(rydepts, pageReqVO1);
         pageReqVO1.setLoginDate(new LocalDateTime[]{beginEndWeek.get("start"), beginEndWeek.get("end")});
@@ -115,6 +117,7 @@ public class AdminUserServiceImpl implements AdminUserService {
 
         DeptDO rd = deptMapper.selectOne("name", "四川瑞都");
         Set<Long> rddepts = deptService.getChildDeptIdListFromCache(rd.getId());
+        rddepts.add(rd.getId());
         UserPageReqVO pageReqVO2 = new UserPageReqVO();
         Long rdtotal = userMapper.selectCountByDeptIds(rddepts, pageReqVO2);
         pageReqVO2.setLoginDate(new LocalDateTime[]{beginEndWeek.get("start"), beginEndWeek.get("end")});