Browse Source

修改bug

lwhhszx 2 năm trước cách đây
mục cha
commit
111bf81350
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      PAS/src/main/java/cn/cslg/pas/service/ProjectService.java

+ 1 - 1
PAS/src/main/java/cn/cslg/pas/service/ProjectService.java

@@ -313,7 +313,7 @@ public class ProjectService extends ServiceImpl<ProjectMapper, Project> {
         List<SystemDict> systemDictList = systemDictService.getSystemDictListByType(Collections.singletonList(Constants.ENTERPRISE_APPLICATION_SCENARIO));
         for (SystemDict systemDict : systemDictList) {
             Map<String, Object> result = new HashMap<>();
-            List<Project> tempList = projectList.stream().filter(item -> item.getScenarioList().contains(Integer.parseInt(systemDict.getValue()))).collect(Collectors.toList());
+            List<Project> tempList = projectList.stream().filter(item ->item.getScenarioList()!=null&& item.getScenarioList().contains(Integer.parseInt(systemDict.getValue()))).collect(Collectors.toList());
             result.put("completed", tempList.stream().filter(item -> item.getStatus().equals("1")).count());
             result.put("unfinished", tempList.stream().filter(item -> item.getStatus().equals("0")).count());
             map.put(systemDict.getLabel(), result);