|
@@ -99,7 +99,7 @@ public class EarlyWarningWithoutSubmitTask { |
|
|
.eq(WflowEarlyWarning::getIsOpen, true); |
|
|
.eq(WflowEarlyWarning::getIsOpen, true); |
|
|
List<WflowEarlyWarning> warnings = earlyWarningService.list(query); |
|
|
List<WflowEarlyWarning> warnings = earlyWarningService.list(query); |
|
|
for (WflowEarlyWarning warning : warnings) { |
|
|
for (WflowEarlyWarning warning : warnings) { |
|
|
long mhUnitId = NumberUtil.parseLong(warning.getAreaCode()); |
|
|
|
|
|
|
|
|
long mhUnitId = warning.getMhUnitId(); |
|
|
List<Long> viewUnitIds = mhUnitCache.getViewChildIdsRecursion(mhUnitId); |
|
|
List<Long> viewUnitIds = mhUnitCache.getViewChildIdsRecursion(mhUnitId); |
|
|
String noticeContent = warning.getNoticeContent(); |
|
|
String noticeContent = warning.getNoticeContent(); |
|
|
String adventContent = warning.getAdventContent(); |
|
|
String adventContent = warning.getAdventContent(); |
|
@@ -123,7 +123,7 @@ public class EarlyWarningWithoutSubmitTask { |
|
|
String path = flowType.getPath(); |
|
|
String path = flowType.getPath(); |
|
|
//查询 所有这个区域的项目 未提交的项目 |
|
|
//查询 所有这个区域的项目 未提交的项目 |
|
|
Wrapper<Project> projectQuery = Wrappers.lambdaQuery(Project.class) |
|
|
Wrapper<Project> projectQuery = Wrappers.lambdaQuery(Project.class) |
|
|
.eq(Project::getBuildOrgCode, viewUnitIds) |
|
|
|
|
|
|
|
|
.eq(Project::getBuildOrgCode, mhUnitId) |
|
|
.eq(Project::getNewest, Boolean.TRUE) |
|
|
.eq(Project::getNewest, Boolean.TRUE) |
|
|
.eq(Project::getStatus, flowType.getProjectStatus().getCode()); |
|
|
.eq(Project::getStatus, flowType.getProjectStatus().getCode()); |
|
|
List<Project> needNextProjects = projectService.list(projectQuery); |
|
|
List<Project> needNextProjects = projectService.list(projectQuery); |
|
@@ -131,10 +131,36 @@ public class EarlyWarningWithoutSubmitTask { |
|
|
List<String> projectCodes = CollUtils.fieldList(needNextProjects, Project::getProjectCode); |
|
|
List<String> projectCodes = CollUtils.fieldList(needNextProjects, Project::getProjectCode); |
|
|
Map<String, ProjectStatusChange> projectStatusChangeMap; |
|
|
Map<String, ProjectStatusChange> projectStatusChangeMap; |
|
|
switch (flowType) { |
|
|
switch (flowType) { |
|
|
case WITHOUT_PURCHASE: |
|
|
|
|
|
|
|
|
// 已资金下达未立项 |
|
|
|
|
|
case FUNDS_ISSUED_NOT_ESTABLISHED_PROJECT:{ |
|
|
|
|
|
projectStatusChangeMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.ANNUAL_PLAN_PASS); |
|
|
|
|
|
} |
|
|
|
|
|
break; |
|
|
|
|
|
// 已立项未开标 |
|
|
|
|
|
case APPROVED_PROJECT_BIT_NOT_OPEN:{ |
|
|
projectStatusChangeMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
projectStatusChangeMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
ProjectStateChangeEvent.DECLARED_RECORD_PASS); |
|
|
ProjectStateChangeEvent.DECLARED_RECORD_PASS); |
|
|
break; |
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
break; |
|
|
|
|
|
// 已开标未采购 |
|
|
|
|
|
case BIT_OPENED_NOT_PURCHASED:{ |
|
|
|
|
|
projectStatusChangeMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.SUBMIT_PURCHASE_NOTICE); |
|
|
|
|
|
} |
|
|
|
|
|
break; |
|
|
|
|
|
// 已采购未改造完成 |
|
|
|
|
|
case PURCHASED_UNMODIFIED:{ |
|
|
|
|
|
projectStatusChangeMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.SUBMIT_PURCHASE_CONTRACT_RECORD); |
|
|
|
|
|
} |
|
|
|
|
|
break; |
|
|
|
|
|
// 已改造完成未终验 |
|
|
|
|
|
case MODIFIED_NOT_FINAL_INSPECTION:{ |
|
|
|
|
|
projectStatusChangeMap = projectStatusChangeService.listLastEventMap(projectCodes, |
|
|
|
|
|
ProjectStateChangeEvent.SUBMIT_PURCHASE_ORG_CONFIRM); |
|
|
|
|
|
} |
|
|
|
|
|
break; |
|
|
default: |
|
|
default: |
|
|
return; |
|
|
return; |
|
|
} |
|
|
} |
|
@@ -170,9 +196,9 @@ public class EarlyWarningWithoutSubmitTask { |
|
|
for (Project needToWaringProject : needToWaringProjects) { |
|
|
for (Project needToWaringProject : needToWaringProjects) { |
|
|
String username; |
|
|
String username; |
|
|
String mobile; |
|
|
String mobile; |
|
|
//去预警通知人 1.项目联系人 2.项目负责人 如果都包含 都要发 |
|
|
|
|
|
|
|
|
//去预警通知人 1.超级管理员 2.单位管理员 如果都包含 都要发 |
|
|
List<String> batchEmployees = Lists.newArrayList(); |
|
|
List<String> batchEmployees = Lists.newArrayList(); |
|
|
if (notice.contains(WarningNoticeTypeEnum.CONTACT.getCode().toString())) { |
|
|
|
|
|
|
|
|
if (notice.contains(WarningNoticeTypeEnum.SUPER_ADMIN.getCode().toString())) { |
|
|
String employeeCode = null; |
|
|
String employeeCode = null; |
|
|
username = needToWaringProject.getContactName(); |
|
|
username = needToWaringProject.getContactName(); |
|
|
mobile = needToWaringProject.getContactPhone(); |
|
|
mobile = needToWaringProject.getContactPhone(); |
|
@@ -186,7 +212,7 @@ public class EarlyWarningWithoutSubmitTask { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
if (notice.contains(WarningNoticeTypeEnum.RESPONSIBLE.getCode().toString())) { |
|
|
|
|
|
|
|
|
if (notice.contains(WarningNoticeTypeEnum.UNIT_ADMIN.getCode().toString())) { |
|
|
String employeeCode = null; |
|
|
String employeeCode = null; |
|
|
username = needToWaringProject.getResponsibleMan(); |
|
|
username = needToWaringProject.getResponsibleMan(); |
|
|
mobile = needToWaringProject.getResponsibleManMobile(); |
|
|
mobile = needToWaringProject.getResponsibleManMobile(); |
|
@@ -349,9 +375,9 @@ public class EarlyWarningWithoutSubmitTask { |
|
|
String sponsor = needToWaringProject.getSponsor(); |
|
|
String sponsor = needToWaringProject.getSponsor(); |
|
|
batchEmployees.add(sponsor); |
|
|
batchEmployees.add(sponsor); |
|
|
} else { |
|
|
} else { |
|
|
//去预警通知人 1.项目联系人 2.项目负责人 如果都包含 都要发 |
|
|
|
|
|
|
|
|
//去预警通知人 1.超级管理员 2.单位管理员 如果都包含 都要发 |
|
|
|
|
|
|
|
|
if (notice.contains(WarningNoticeTypeEnum.CONTACT.getCode().toString())) { |
|
|
|
|
|
|
|
|
if (notice.contains(WarningNoticeTypeEnum.SUPER_ADMIN.getCode().toString())) { |
|
|
String employeeCode = null; |
|
|
String employeeCode = null; |
|
|
String username = needToWaringProject.getContactName(); |
|
|
String username = needToWaringProject.getContactName(); |
|
|
String mobile = needToWaringProject.getContactPhone(); |
|
|
String mobile = needToWaringProject.getContactPhone(); |
|
@@ -365,7 +391,7 @@ public class EarlyWarningWithoutSubmitTask { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
if (notice.contains(WarningNoticeTypeEnum.RESPONSIBLE.getCode().toString())) { |
|
|
|
|
|
|
|
|
if (notice.contains(WarningNoticeTypeEnum.UNIT_ADMIN.getCode().toString())) { |
|
|
String employeeCode = null; |
|
|
String employeeCode = null; |
|
|
String username = needToWaringProject.getResponsibleMan(); |
|
|
String username = needToWaringProject.getResponsibleMan(); |
|
|
String mobile = needToWaringProject.getResponsibleManMobile(); |
|
|
String mobile = needToWaringProject.getResponsibleManMobile(); |
|
|