Browse Source

工作台整改

tags/24080901
PoffyZhang 1 year ago
parent
commit
e4e39e1655
1 changed files with 4 additions and 2 deletions
  1. +4
    -2
      pmapi/src/main/java/com/ningdatech/pmapi/projectlib/manage/ProjectLibManage.java

+ 4
- 2
pmapi/src/main/java/com/ningdatech/pmapi/projectlib/manage/ProjectLibManage.java View File

@@ -10,6 +10,7 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import com.google.common.collect.Sets;
import com.ningdatech.basic.function.VUtils;
import com.ningdatech.basic.model.PageVo;
import com.ningdatech.basic.util.CollUtils;
@@ -358,13 +359,14 @@ public class ProjectLibManage {
}

private Map<String, UserFullInfoDTO> searchUser(List<Task> tasks, UserInfoHelper userInfoHelper) {
if(CollUtil.isNotEmpty(tasks)){
if(CollUtil.isEmpty(tasks)){
return Collections.emptyMap();
}
List<UserFullInfoDTO> users = userInfoHelper.getUserFullInfoByEmployeeCodes(
tasks.stream().map(Task::getAssignee).collect(Collectors.toSet()));
if(CollUtil.isNotEmpty(users)){
return users.stream().collect(Collectors
Set<String> employeeSet = Sets.newHashSet();
return users.stream().filter(u -> employeeSet.add(u.getEmployeeCode())).collect(Collectors
.toMap(UserFullInfoDTO::getEmployeeCode,u -> u));
}
return Collections.emptyMap();


Loading…
Cancel
Save