feat:[REQ-3488] 修改岗位过滤BUG

This commit is contained in:
liuyang 2025-02-19 15:35:52 +08:00
parent 873b281d02
commit 137b993829

View File

@ -105,15 +105,15 @@ public class CooperateShipFoundationServiceImpl implements CooperateShipFoundati
return;
}
Map<Long, OrgJobQueryRepository.JobResp> jobMap = CollStreamUtil.toMap(jobList, OrgJob::getId, Function.identity());
List<Long> jobNodeIds = nodeUsers.stream().filter(t -> {
List<Long> excludeJobNodeIds = nodeUsers.stream().filter(t -> {
OrgJobQueryRepository.JobResp job = jobMap.get(t.getOrganizationalJobId());
// 岗位不存在不做排除
if (job == null) {
return true;
return false;
}
return excludeJobCodes.contains(job.getCode());
}).map(OrganizationalNodeUser::getTopNodeId).collect(Collectors.toList());
nodeIds.removeIf(t -> !jobNodeIds.contains(t));
nodeIds.removeIf(t -> excludeJobNodeIds.contains(t));
}
// 删除原协同关系节点