diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java index 983dd27..8de8b4c 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java @@ -648,7 +648,10 @@ public class TodoCenterManage { List projectInstList = projectInstService.list(Wrappers.lambdaQuery(ProjectInst.class) .in(ProjectInst::getProjectId, projectIdList) .orderByDesc(ProjectInst::getProjectId)); - Map projectInfoMap = projectInstList.stream().collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); + Map projectInfoMap = projectInstList.stream() + .filter(p -> StringUtils.isNotBlank(p.getInstCode()) && + !TodoCenterConstant.Declared.NULL_INST_CODE.equals(p.getInstCode())) + .collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); List instCodes = projectInstList.stream().map(ProjectInst::getInstCode).collect(Collectors.toList()); // 查出用户工作流 @@ -719,7 +722,10 @@ public class TodoCenterManage { List projectInstList = projectInstService.list(Wrappers.lambdaQuery(ProjectInst.class) .in(ProjectInst::getProjectId, projectIdList) .orderByDesc(ProjectInst::getProjectId)); - projectInfoMap = projectInstList.stream().collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); + projectInfoMap = projectInstList.stream() + .filter(p -> StringUtils.isNotBlank(p.getInstCode()) && + !TodoCenterConstant.Declared.NULL_INST_CODE.equals(p.getInstCode())) + .collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); List instCodes = projectInstList.stream().map(ProjectInst::getInstCode).collect(Collectors.toList()); // 查出用户工作流 @@ -788,7 +794,10 @@ public class TodoCenterManage { List projectInstList = projectInstService.list(Wrappers.lambdaQuery(ProjectInst.class) .in(ProjectInst::getProjectId, projectIdList) .orderByDesc(ProjectInst::getProjectId)); - Map projectInfoMap = projectInstList.stream().collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); + Map projectInfoMap = projectInstList.stream() + .filter(p -> StringUtils.isNotBlank(p.getInstCode()) && + !TodoCenterConstant.Declared.NULL_INST_CODE.equals(p.getInstCode())) + .collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); List instCodes = projectInstList.stream().map(ProjectInst::getInstCode).collect(Collectors.toList()); // 查出用户工作流 @@ -857,7 +866,10 @@ public class TodoCenterManage { List projectInstList = projectInstService.list(Wrappers.lambdaQuery(ProjectInst.class) .in(ProjectInst::getProjectId, projectIdList) .orderByDesc(ProjectInst::getProjectId)); - projectInfoMap = projectInstList.stream().collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); + projectInfoMap = projectInstList.stream() + .filter(p -> StringUtils.isNotBlank(p.getInstCode()) && + !TodoCenterConstant.Declared.NULL_INST_CODE.equals(p.getInstCode())) + .collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); List instCodes = projectInstList.stream().map(ProjectInst::getInstCode).collect(Collectors.toList()); // 查出用户工作流 @@ -927,7 +939,10 @@ public class TodoCenterManage { List projectInstList = projectInstService.list(Wrappers.lambdaQuery(ProjectInst.class) .in(ProjectInst::getProjectId, projectIdList) .orderByDesc(ProjectInst::getProjectId)); - Map projectInfoMap = projectInstList.stream().collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); + Map projectInfoMap = projectInstList.stream() + .filter(p -> StringUtils.isNotBlank(p.getInstCode()) && + !TodoCenterConstant.Declared.NULL_INST_CODE.equals(p.getInstCode())) + .collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); List instCodes = projectInstList.stream().map(ProjectInst::getInstCode).collect(Collectors.toList()); // 查出用户工作流 @@ -997,7 +1012,10 @@ public class TodoCenterManage { List projectInstList = projectInstService.list(Wrappers.lambdaQuery(ProjectInst.class) .in(ProjectInst::getProjectId, projectIdList) .orderByDesc(ProjectInst::getProjectId)); - projectInfoMap = projectInstList.stream().collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); + projectInfoMap = projectInstList.stream() + .filter(p -> StringUtils.isNotBlank(p.getInstCode()) && + !TodoCenterConstant.Declared.NULL_INST_CODE.equals(p.getInstCode())) + .collect(Collectors.toMap(ProjectInst::getInstCode, p -> projectsMap.get(p.getProjectId()))); List instCodes = projectInstList.stream().map(ProjectInst::getInstCode).collect(Collectors.toList()); // 分页查出用户工作流