fix(标准主计划): 完善
This commit is contained in:
+21
-18
@@ -138,12 +138,22 @@ public class LawsStandardMasterPlanServiceImpl
|
|||||||
String type = lawsStandardMasterPlanSublist.getType();
|
String type = lawsStandardMasterPlanSublist.getType();
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case LawsStandardMasterPlanCommon.INTERPRETATION_OF_REGULATIONS:
|
case LawsStandardMasterPlanCommon.INTERPRETATION_OF_REGULATIONS:
|
||||||
ProcessAll processAll = processAllService.getOne(new LambdaQueryWrapper<ProcessAll>()
|
List<ProcessStandardInterpret> list = processStandardInterpretService.list(
|
||||||
.eq(ProcessAll::getPrcType, "2")
|
new LambdaQueryWrapper<ProcessStandardInterpret>()
|
||||||
.eq(ProcessAll::getPrcStatus, ProcessStatusEnum.COMPLETED.getValue())
|
.eq(ProcessStandardInterpret::getStandardId,
|
||||||
.orderByAsc(ProcessAll::getCreateTime).last("limit 1"));
|
lawsStandardMasterPlan.getStandardId()));
|
||||||
if (!Objects.isNull(processAll)){
|
if (CollectionUtils.isNotEmpty(list)){
|
||||||
lawsStandardMasterPlanSublist.setAssociationId(processAll.getId());
|
List<String> projectIdList = list.stream()
|
||||||
|
.map(ProcessStandardInterpret::getProjectId)
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
ProcessAll processAll = processAllService.getOne(new LambdaQueryWrapper<ProcessAll>()
|
||||||
|
.in(ProcessAll::getProjectId, projectIdList)
|
||||||
|
.eq(ProcessAll::getPrcType, "2")
|
||||||
|
.eq(ProcessAll::getPrcStatus, ProcessStatusEnum.COMPLETED.getValue())
|
||||||
|
.orderByAsc(ProcessAll::getCreateTime).last("limit 1"));
|
||||||
|
if (!Objects.isNull(processAll)){
|
||||||
|
lawsStandardMasterPlanSublist.setAssociationId(processAll.getId());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case LawsStandardMasterPlanCommon.MARKET_REGULATION_LIST_UPDATE:
|
case LawsStandardMasterPlanCommon.MARKET_REGULATION_LIST_UPDATE:
|
||||||
@@ -247,23 +257,16 @@ public class LawsStandardMasterPlanServiceImpl
|
|||||||
new LambdaQueryWrapper<ProcessNewStandardImport>()
|
new LambdaQueryWrapper<ProcessNewStandardImport>()
|
||||||
.eq(ProcessNewStandardImport::getStandardId, lawsStandardMasterPlan.getStandardId())
|
.eq(ProcessNewStandardImport::getStandardId, lawsStandardMasterPlan.getStandardId())
|
||||||
.eq(ProcessNewStandardImport::getApplicableMarket,
|
.eq(ProcessNewStandardImport::getApplicableMarket,
|
||||||
lawsStandardMasterPlan.getApplicableMarket())
|
lawsStandardMasterPlan.getApplicableMarket()));
|
||||||
.orderByAsc(ProcessNewStandardImport::getCreateTime));
|
|
||||||
if (CollectionUtils.isNotEmpty(list1)){
|
if (CollectionUtils.isNotEmpty(list1)){
|
||||||
ProcessNewStandardImport processNewStandardImport = list1.get(0);
|
|
||||||
ProcessAll processAll = processAllService.getOne(new LambdaQueryWrapper<ProcessAll>()
|
|
||||||
.eq(ProcessAll::getProcessInstanceId,
|
|
||||||
processNewStandardImport.getProcessInstanceId())
|
|
||||||
.eq(ProcessAll::getPrcStatus,ProcessStatusEnum.COMPLETED.getValue()));
|
|
||||||
if (!Objects.isNull(processAll)){
|
|
||||||
lawsStandardMasterPlanSublist.setActualCompletionDate(processAll.getEndTime());
|
|
||||||
}
|
|
||||||
|
|
||||||
List<String> processInstanceIdList = list1.stream()
|
List<String> processInstanceIdList = list1.stream()
|
||||||
.map(ProcessNewStandardImport::getProcessInstanceId).collect(Collectors.toList());
|
.map(ProcessNewStandardImport::getProcessInstanceId).collect(Collectors.toList());
|
||||||
List<ProcessAll> processAllList = processAllService.list(new LambdaQueryWrapper<ProcessAll>()
|
List<ProcessAll> processAllList = processAllService.list(new LambdaQueryWrapper<ProcessAll>()
|
||||||
.in(ProcessAll::getProcessInstanceId, processInstanceIdList));
|
.in(ProcessAll::getProcessInstanceId, processInstanceIdList)
|
||||||
|
.orderByAsc(ProcessAll::getEndTime));
|
||||||
if (CollectionUtils.isNotEmpty(processAllList)){
|
if (CollectionUtils.isNotEmpty(processAllList)){
|
||||||
|
ProcessAll processAll = processAllList.get(0);
|
||||||
|
lawsStandardMasterPlanSublist.setActualCompletionDate(processAll.getEndTime());
|
||||||
lawsStandardMasterPlanSublist.setProcessAllList(processAllList);
|
lawsStandardMasterPlanSublist.setProcessAllList(processAllList);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user