Showing
1 changed file
with
6 additions
and
9 deletions
xingyun-sc/src/main/java/com/lframework/xingyun/sc/controller/ledger/FundCoordinationController.java
| ... | ... | @@ -199,15 +199,12 @@ public class FundCoordinationController extends DefaultBaseController { |
| 199 | 199 | public InvokeResult<List<QuerySysUserBo>> getFundResponsiblePersonList() { |
| 200 | 200 | List<QuerySysUserBo> results = null; |
| 201 | 201 | String userId = SecurityUtil.getCurrentUser().getId(); |
| 202 | - SysDept dept = sysDeptService.getDept(userId); | |
| 203 | - if (dept != null) { | |
| 204 | - QuerySysUserVo vo = new QuerySysUserVo(); | |
| 205 | - vo.setDeptCode(dept.getCode()); | |
| 206 | - List<String> userIds = sysUserDeptService.listAllUserByDeptId(dept.getId(), true); | |
| 207 | - if (!CollectionUtil.isEmpty(userIds)) { | |
| 208 | - List<SysUser> datas = sysUserService.listByUserId(userIds); | |
| 209 | - results = datas.stream().map(QuerySysUserBo::new).collect(Collectors.toList()); | |
| 210 | - } | |
| 202 | + List<String> ids = new ArrayList<>(); | |
| 203 | + ids.add(userId); | |
| 204 | + Map<String, List<String>> map = sysUserDeptService.mapAllUserByUserId(ids, true); | |
| 205 | + if (!CollectionUtil.isEmpty(map)) { | |
| 206 | + List<SysUser> datas = sysUserService.listByUserId(map.get(userId)); | |
| 207 | + results = datas.stream().map(QuerySysUserBo::new).collect(Collectors.toList()); | |
| 211 | 208 | } |
| 212 | 209 | return InvokeResultBuilder.success(results); |
| 213 | 210 | } | ... | ... |