|
@@ -708,10 +708,11 @@ public class UserServiceImpl extends BaseServiceImpl<UserMapper, User> implement
|
|
Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(WbsTreeContractLazyVO::getPKeyId))),
|
|
Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(WbsTreeContractLazyVO::getPKeyId))),
|
|
ArrayList::new
|
|
ArrayList::new
|
|
));
|
|
));
|
|
- List<WbsTreeContractLazyVO> distinctLowestNodesAll = distinctNodesAll.stream().filter(f -> f.getHasChildren().equals(0)).collect(Collectors.collectingAndThen(
|
|
|
|
- Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(WbsTreeContractLazyVO::getPKeyId))),
|
|
|
|
- ArrayList::new
|
|
|
|
- ));
|
|
|
|
|
|
+ List<WbsTreeContractLazyVO> distinctLowestNodesAll = distinctNodesAll.stream().filter(f -> f.getHasChildren().equals(0))
|
|
|
|
+ .collect(Collectors.collectingAndThen(
|
|
|
|
+ Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(WbsTreeContractLazyVO::getPKeyId))),
|
|
|
|
+ ArrayList::new
|
|
|
|
+ ));
|
|
|
|
|
|
/*获取当前合同段节点对应的资料填报QueryInfo本地缓存信息*/
|
|
/*获取当前合同段节点对应的资料填报QueryInfo本地缓存信息*/
|
|
List<WbsTreeContractLazyQueryInfoVO> queryInfoList = this.getQueryInfoList(contractId, tableOwner);
|
|
List<WbsTreeContractLazyQueryInfoVO> queryInfoList = this.getQueryInfoList(contractId, tableOwner);
|
|
@@ -722,25 +723,13 @@ public class UserServiceImpl extends BaseServiceImpl<UserMapper, User> implement
|
|
/* ================ 处理数量 ================ */
|
|
/* ================ 处理数量 ================ */
|
|
List<WbsTreeContractLazyVO> lowestNodesTB = distinctLowestNodesAll.parallelStream().filter(f -> pKeyIdList.contains(f.getPKeyId())).collect(Collectors.toList());
|
|
List<WbsTreeContractLazyVO> lowestNodesTB = distinctLowestNodesAll.parallelStream().filter(f -> pKeyIdList.contains(f.getPKeyId())).collect(Collectors.toList());
|
|
List<Long> lowestNodeParentIdsTB = lowestNodesTB.parallelStream().map(WbsTreeContractLazyVO::getParentId).collect(Collectors.toList());
|
|
List<Long> lowestNodeParentIdsTB = lowestNodesTB.parallelStream().map(WbsTreeContractLazyVO::getParentId).collect(Collectors.toList());
|
|
- /*获取当前合同段节点对应计数统计本地缓存信息*/
|
|
|
|
List<WbsTreeContractLazyVO> resultParentNodesTB = this.getCachedParentCountNodes(contractId, lowestNodeParentIdsTB, nodesAll, tableOwner);
|
|
List<WbsTreeContractLazyVO> resultParentNodesTB = this.getCachedParentCountNodes(contractId, lowestNodeParentIdsTB, nodesAll, tableOwner);
|
|
-
|
|
|
|
- /*List<WbsTreeContractLazyVO> resultParentNodesTB = new ArrayList<>();
|
|
|
|
- long startTime1 = System.currentTimeMillis();
|
|
|
|
- this.recursiveGetParentNodes(resultParentNodesTB, lowestNodeParentIdsTB, nodesAll);
|
|
|
|
- long endTime1 = System.currentTimeMillis();
|
|
|
|
- long executionTime1 = endTime1 - startTime1;
|
|
|
|
- _logger.info("合同段 " + contractId + " wbs节点树 数量计算 执行时间:" + executionTime1 + " ms");*/
|
|
|
|
-
|
|
|
|
Map<Long, WbsTreeContractLazyVO> lowestNodesMap = lowestNodesTB.stream()
|
|
Map<Long, WbsTreeContractLazyVO> lowestNodesMap = lowestNodesTB.stream()
|
|
.peek(vo -> {
|
|
.peek(vo -> {
|
|
Integer colorStatus = queryInfoMaps.get(vo.getPKeyId());
|
|
Integer colorStatus = queryInfoMaps.get(vo.getPKeyId());
|
|
if (colorStatus != null) {
|
|
if (colorStatus != null) {
|
|
- //任务状态0=未上报=颜色2蓝色、任务状态1=待审批=颜色3橙色、任务状态2=已审批=颜色4绿色、
|
|
|
|
- ///*任务状态3=已废除=颜色1黑色*/(2023年10月16日13:59:00 已废除改为=颜色2蓝色)
|
|
|
|
vo.setColorStatus(colorStatus == 0 ? 2 : (colorStatus == 1 ? 3 : (colorStatus == 2 ? 4 : 2)));
|
|
vo.setColorStatus(colorStatus == 0 ? 2 : (colorStatus == 1 ? 3 : (colorStatus == 2 ? 4 : 2)));
|
|
} else {
|
|
} else {
|
|
- //未填报的=颜色1黑色
|
|
|
|
vo.setColorStatus(1);
|
|
vo.setColorStatus(1);
|
|
}
|
|
}
|
|
}).collect(Collectors.toMap(WbsTreeContractLazyVO::getPKeyId, Function.identity()));
|
|
}).collect(Collectors.toMap(WbsTreeContractLazyVO::getPKeyId, Function.identity()));
|
|
@@ -824,10 +813,11 @@ public class UserServiceImpl extends BaseServiceImpl<UserMapper, User> implement
|
|
Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(WbsTreeContractLazyVO::getPKeyId))),
|
|
Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(WbsTreeContractLazyVO::getPKeyId))),
|
|
ArrayList::new
|
|
ArrayList::new
|
|
));
|
|
));
|
|
- List<WbsTreeContractLazyVO> distinctLowestNodesAll = distinctNodesAll.stream().filter(f -> f.getHasChildren().equals(0)).collect(Collectors.collectingAndThen(
|
|
|
|
- Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(WbsTreeContractLazyVO::getPKeyId))),
|
|
|
|
- ArrayList::new
|
|
|
|
- ));
|
|
|
|
|
|
+ List<WbsTreeContractLazyVO> distinctLowestNodesAll = distinctNodesAll.stream().filter(f -> f.getHasChildren().equals(0))
|
|
|
|
+ .collect(Collectors.collectingAndThen(
|
|
|
|
+ Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(WbsTreeContractLazyVO::getPKeyId))),
|
|
|
|
+ ArrayList::new
|
|
|
|
+ ));
|
|
|
|
|
|
List<WbsTreeContractLazyQueryInfoVO> queryInfoList = this.getQueryInfoList(sgContractId, tableOwner);
|
|
List<WbsTreeContractLazyQueryInfoVO> queryInfoList = this.getQueryInfoList(sgContractId, tableOwner);
|
|
|
|
|
|
@@ -837,9 +827,7 @@ public class UserServiceImpl extends BaseServiceImpl<UserMapper, User> implement
|
|
|
|
|
|
List<WbsTreeContractLazyVO> lowestNodesTB = distinctLowestNodesAll.parallelStream().filter(f -> pKeyIdList.contains(f.getPKeyId())).collect(Collectors.toList());
|
|
List<WbsTreeContractLazyVO> lowestNodesTB = distinctLowestNodesAll.parallelStream().filter(f -> pKeyIdList.contains(f.getPKeyId())).collect(Collectors.toList());
|
|
List<Long> lowestNodeParentIdsTB = lowestNodesTB.parallelStream().map(WbsTreeContractLazyVO::getParentId).collect(Collectors.toList());
|
|
List<Long> lowestNodeParentIdsTB = lowestNodesTB.parallelStream().map(WbsTreeContractLazyVO::getParentId).collect(Collectors.toList());
|
|
-
|
|
|
|
List<WbsTreeContractLazyVO> resultParentNodesTB = this.getCachedParentCountNodes(sgContractId, lowestNodeParentIdsTB, nodesAll, tableOwner);
|
|
List<WbsTreeContractLazyVO> resultParentNodesTB = this.getCachedParentCountNodes(sgContractId, lowestNodeParentIdsTB, nodesAll, tableOwner);
|
|
-
|
|
|
|
Map<Long, WbsTreeContractLazyVO> lowestNodesMap = lowestNodesTB.stream()
|
|
Map<Long, WbsTreeContractLazyVO> lowestNodesMap = lowestNodesTB.stream()
|
|
.peek(vo -> {
|
|
.peek(vo -> {
|
|
Integer colorStatus = queryInfoMaps.get(vo.getPKeyId());
|
|
Integer colorStatus = queryInfoMaps.get(vo.getPKeyId());
|