add 统计报表-科室总体统计

This commit is contained in:
lijiarao
2022-06-11 17:25:14 +08:00
parent f6c9d003af
commit a01d0db2c8
10 changed files with 208 additions and 23 deletions
@@ -40,7 +40,6 @@ import com.jero.modules.system.service.*;
import com.jero.modules.system.util.SecurityUtil;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cache.annotation.CacheEvict;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.stereotype.Service;
import org.springframework.util.AntPathMatcher;
@@ -1072,13 +1071,28 @@ public class SysBaseApiImpl implements ISysBaseAPI {
@Override
//获取本部门下全部子部门的全部成员(不包含本部门)
public List<String> getAllDepartIds(String departId,List<String> idList) {
public List<String> getAllUserIdsByDepart(String departId, List<String> idList) {
List<SysDepartTreeModel> sysDepartTreeModels =listSonDepartsByDepId(departId);
if(!(sysDepartTreeModels.size()==0)) {
for (SysDepartTreeModel s : sysDepartTreeModels) {
idList.addAll((userMapper.selectList(new QueryWrapper<SysUser>().eq("status", 1).eq("del_flag", 0).eq("org_code", s.getOrgCode()))).stream().map(SysUser::getId).collect(Collectors.toList()));
getAllDepartIds(s.getId(),idList);
getAllUserIdsByDepart(s.getId(),idList);
}
return idList;
}
return idList;
}
@Override
//获取本部门下全部子部门的id(包含本部门)
public List<String> getAllDepartIdsByDepart(String departId, List<String> idList) {
List<SysDepartTreeModel> sysDepartTreeModels =listSonDepartsByDepId(departId);
if(!(sysDepartTreeModels.size()==0)) {
for (SysDepartTreeModel s : sysDepartTreeModels) {
idList.add(s.getId());
getAllUserIdsByDepart(s.getId(),idList);
}
return idList;
}