|
@@ -2146,6 +2146,8 @@ public class IotStaticController {
|
|
|
Map<Long, String> projectPair = new HashMap<>();
|
|
Map<Long, String> projectPair = new HashMap<>();
|
|
|
// key项目部id value项目部包含的队伍id集合
|
|
// key项目部id value项目部包含的队伍id集合
|
|
|
Map<Long, Set<Long>> projectTeamPair = new HashMap<>();
|
|
Map<Long, Set<Long>> projectTeamPair = new HashMap<>();
|
|
|
|
|
+ // 队伍id 集合
|
|
|
|
|
+ Set<Long> crewIds = new HashSet<>();
|
|
|
if (CollUtil.isNotEmpty(allDeptPair)) {
|
|
if (CollUtil.isNotEmpty(allDeptPair)) {
|
|
|
allDeptPair.forEach((deptId, dept) -> {
|
|
allDeptPair.forEach((deptId, dept) -> {
|
|
|
if ("2".equals(dept.getType())) {
|
|
if ("2".equals(dept.getType())) {
|
|
@@ -2153,11 +2155,15 @@ public class IotStaticController {
|
|
|
projectDeptNames.add(dept.getName());
|
|
projectDeptNames.add(dept.getName());
|
|
|
projectPair.put(deptId, dept.getName());
|
|
projectPair.put(deptId, dept.getName());
|
|
|
}
|
|
}
|
|
|
|
|
+ if ("3".equals(dept.getType())) {
|
|
|
|
|
+ // 队伍
|
|
|
|
|
+ crewIds.add(dept.getId());
|
|
|
|
|
+ }
|
|
|
});
|
|
});
|
|
|
// 遍历所有部门
|
|
// 遍历所有部门
|
|
|
allDeptPair.forEach((deptId, dept) -> {
|
|
allDeptPair.forEach((deptId, dept) -> {
|
|
|
// 找出每个项目部下的队伍
|
|
// 找出每个项目部下的队伍
|
|
|
- if (projectPair.containsKey(dept.getParentId())) {
|
|
|
|
|
|
|
+ if (projectPair.containsKey(dept.getParentId()) && 0==dept.getStatus()) {
|
|
|
// 获得当前部门的上级项目部
|
|
// 获得当前部门的上级项目部
|
|
|
projectPair.forEach((projectDeptId, projectDept) -> {
|
|
projectPair.forEach((projectDeptId, projectDept) -> {
|
|
|
if (projectDeptId.equals(dept.getParentId())) {
|
|
if (projectDeptId.equals(dept.getParentId())) {
|
|
@@ -2282,7 +2288,9 @@ public class IotStaticController {
|
|
|
Set<Long> projectTeamIds = new HashSet<>();
|
|
Set<Long> projectTeamIds = new HashSet<>();
|
|
|
if (CollUtil.isNotEmpty(projectTeams)) {
|
|
if (CollUtil.isNotEmpty(projectTeams)) {
|
|
|
projectTeams.forEach(team -> {
|
|
projectTeams.forEach(team -> {
|
|
|
- projectTeamIds.add(team.getId());
|
|
|
|
|
|
|
+ if ("3".equals(team.getType())) {
|
|
|
|
|
+ projectTeamIds.add(team.getId());
|
|
|
|
|
+ }
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
|
|
|