|
@@ -138,31 +138,37 @@ public class DelayWarningTest extends AppTests { |
|
|
switch (flowType) { |
|
|
switch (flowType) { |
|
|
// 已立项未采购 获取 立项时间 |
|
|
// 已立项未采购 获取 立项时间 |
|
|
case APPROVED_PROJECT_NOT_PURCHASED:{ |
|
|
case APPROVED_PROJECT_NOT_PURCHASED:{ |
|
|
Map<String, ProjectStatusChange> approvedProjectNotPurchasedMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.DECLARED_RECORD_PASS); |
|
|
|
|
|
if (CollUtil.isNotEmpty(approvedProjectNotPurchasedMap)){ |
|
|
|
|
|
projectStatusChangeMap.putAll(approvedProjectNotPurchasedMap); |
|
|
|
|
|
stepName = TaskConstant.StepName.PURCHASE; |
|
|
|
|
|
|
|
|
stepName = TaskConstant.StepName.PURCHASE; |
|
|
|
|
|
if (CollUtil.isNotEmpty(projectCodes)) { |
|
|
|
|
|
Map<String, ProjectStatusChange> approvedProjectNotPurchasedMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.DECLARED_RECORD_PASS); |
|
|
|
|
|
if (CollUtil.isNotEmpty(approvedProjectNotPurchasedMap)) { |
|
|
|
|
|
projectStatusChangeMap.putAll(approvedProjectNotPurchasedMap); |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
break; |
|
|
break; |
|
|
// 已采购未改造完成 获取合同签订时间 |
|
|
// 已采购未改造完成 获取合同签订时间 |
|
|
case PURCHASED_UNMODIFIED:{ |
|
|
case PURCHASED_UNMODIFIED:{ |
|
|
Map<String, ProjectStatusChange> purchasedUnmodifiedMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.SUBMIT_PURCHASE_CONTRACT_RECORD); |
|
|
|
|
|
if (CollUtil.isNotEmpty(purchasedUnmodifiedMap)){ |
|
|
|
|
|
projectStatusChangeMap.putAll(purchasedUnmodifiedMap); |
|
|
|
|
|
stepName = TaskConstant.StepName.ADAPT_MODIFY; |
|
|
|
|
|
|
|
|
stepName = TaskConstant.StepName.ADAPT_MODIFY; |
|
|
|
|
|
if (CollUtil.isNotEmpty(projectCodes)) { |
|
|
|
|
|
Map<String, ProjectStatusChange> purchasedUnmodifiedMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.SUBMIT_PURCHASE_CONTRACT_RECORD); |
|
|
|
|
|
if (CollUtil.isNotEmpty(purchasedUnmodifiedMap)) { |
|
|
|
|
|
projectStatusChangeMap.putAll(purchasedUnmodifiedMap); |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
break; |
|
|
break; |
|
|
// 已改造完成未终验 获取单位确认时间 |
|
|
// 已改造完成未终验 获取单位确认时间 |
|
|
case MODIFIED_NOT_FINAL_INSPECTION:{ |
|
|
case MODIFIED_NOT_FINAL_INSPECTION:{ |
|
|
Map<String, ProjectStatusChange> modifiedNotFinalInspectionMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.SUBMIT_PURCHASE_ORG_CONFIRM); |
|
|
|
|
|
if (CollUtil.isNotEmpty(modifiedNotFinalInspectionMap)){ |
|
|
|
|
|
projectStatusChangeMap.putAll(modifiedNotFinalInspectionMap); |
|
|
|
|
|
stepName = TaskConstant.StepName.FINAL; |
|
|
|
|
|
|
|
|
stepName = TaskConstant.StepName.FINAL; |
|
|
|
|
|
if (CollUtil.isNotEmpty(projectCodes)) { |
|
|
|
|
|
Map<String, ProjectStatusChange> modifiedNotFinalInspectionMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.SUBMIT_PURCHASE_ORG_CONFIRM); |
|
|
|
|
|
if (CollUtil.isNotEmpty(modifiedNotFinalInspectionMap)) { |
|
|
|
|
|
projectStatusChangeMap.putAll(modifiedNotFinalInspectionMap); |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
break; |
|
|
break; |
|
@@ -308,8 +314,8 @@ public class DelayWarningTest extends AppTests { |
|
|
if (!projectStatus.eq(project.getStatus())) { |
|
|
if (!projectStatus.eq(project.getStatus())) { |
|
|
checkCommited(delay, flowTypeEnum, projectCode); |
|
|
checkCommited(delay, flowTypeEnum, projectCode); |
|
|
// 其它几种 都没有 说明已经正常了 |
|
|
// 其它几种 都没有 说明已经正常了 |
|
|
if (!delay.getProcessWarning() && |
|
|
|
|
|
!delay.getDeclaredWarning()) { |
|
|
|
|
|
|
|
|
if (Boolean.FALSE.equals(delay.getProcessWarning()) && |
|
|
|
|
|
Boolean.FALSE.equals(delay.getDeclaredWarning())) { |
|
|
delay.setNormal(Boolean.TRUE); |
|
|
delay.setNormal(Boolean.TRUE); |
|
|
delay.setStatus(ProjectEarlyWarningStatusEnum.NORMAL.name()); |
|
|
delay.setStatus(ProjectEarlyWarningStatusEnum.NORMAL.name()); |
|
|
} |
|
|
} |
|
@@ -346,8 +352,8 @@ public class DelayWarningTest extends AppTests { |
|
|
if (!projectStatus.eq(project.getStatus())) { |
|
|
if (!projectStatus.eq(project.getStatus())) { |
|
|
checkCommited(declaredWarning, flowTypeEnum, projectCode); |
|
|
checkCommited(declaredWarning, flowTypeEnum, projectCode); |
|
|
// 其它几种 都没有 说明已经正常了 |
|
|
// 其它几种 都没有 说明已经正常了 |
|
|
if (!declaredWarning.getProcessWarning() && |
|
|
|
|
|
!declaredWarning.getDelayWarning()) { |
|
|
|
|
|
|
|
|
if (Boolean.FALSE.equals(declaredWarning.getProcessWarning()) && |
|
|
|
|
|
Boolean.FALSE.equals(declaredWarning.getDelayWarning())) { |
|
|
declaredWarning.setNormal(Boolean.TRUE); |
|
|
declaredWarning.setNormal(Boolean.TRUE); |
|
|
declaredWarning.setStatus(ProjectEarlyWarningStatusEnum.NORMAL.name()); |
|
|
declaredWarning.setStatus(ProjectEarlyWarningStatusEnum.NORMAL.name()); |
|
|
} |
|
|
} |
|
@@ -424,8 +430,8 @@ public class DelayWarningTest extends AppTests { |
|
|
//说明 已经审批通过了 |
|
|
//说明 已经审批通过了 |
|
|
processWarning.setProcessWarning(Boolean.FALSE); |
|
|
processWarning.setProcessWarning(Boolean.FALSE); |
|
|
//其它三种 都没有 说明已经正常了 |
|
|
//其它三种 都没有 说明已经正常了 |
|
|
if (!processWarning.getDeclaredWarning() && |
|
|
|
|
|
!processWarning.getDelayWarning()) { |
|
|
|
|
|
|
|
|
if (Boolean.FALSE.equals(processWarning.getDeclaredWarning()) && |
|
|
|
|
|
Boolean.FALSE.equals(processWarning.getDelayWarning())) { |
|
|
processWarning.setNormal(Boolean.TRUE); |
|
|
processWarning.setNormal(Boolean.TRUE); |
|
|
processWarning.setStatus(ProjectEarlyWarningStatusEnum.NORMAL.name()); |
|
|
processWarning.setStatus(ProjectEarlyWarningStatusEnum.NORMAL.name()); |
|
|
} |
|
|
} |
|
|