|
|
@ -345,6 +345,7 @@ public class IssueServiceImpl extends BaseServiceImpl<IssueDao, IssueEntity> imp |
|
|
|
applicationParam.put(ModuleConstants.FIELD_JAVA_TOPIC_ID, param.getTopicId()); |
|
|
|
List<IssueApplicationDTO> applicationList = applicationService.list(applicationParam); |
|
|
|
List<String> applyIds = new LinkedList<>(); |
|
|
|
boolean ifRepeat = false; |
|
|
|
//没有历史提交记录
|
|
|
|
if (CollectionUtils.isEmpty(applicationList)) { |
|
|
|
//审核开关开启
|
|
|
@ -358,6 +359,7 @@ public class IssueServiceImpl extends BaseServiceImpl<IssueDao, IssueEntity> imp |
|
|
|
} |
|
|
|
} else { |
|
|
|
//重新提交 或 工作端审核议题 更新application
|
|
|
|
if(!isStaffAudition) ifRepeat = true; |
|
|
|
if (applicationList.size() > NumConstant.ONE) |
|
|
|
logger.error("com.epmet.service.impl.IssueServiceImpl.topicShiftedToIssueV2,查出多条转移提提交记录,话题Id:{}", param.getTopicId()); |
|
|
|
|
|
|
@ -376,19 +378,21 @@ public class IssueServiceImpl extends BaseServiceImpl<IssueDao, IssueEntity> imp |
|
|
|
|
|
|
|
applyIds.add(apply.getId()); |
|
|
|
}); |
|
|
|
|
|
|
|
if(!ifRepeat) { |
|
|
|
//新增history
|
|
|
|
applyIds.forEach(id -> { |
|
|
|
|
|
|
|
IssueApplicationHistoryDTO history = new IssueApplicationHistoryDTO(); |
|
|
|
history.setActionType(defaultStatusUnderAuditing); |
|
|
|
history.setCreatedTime(param.getCreatedTime()); |
|
|
|
history.setCustomerId(param.getCustomerId()); |
|
|
|
history.setIssueApplicationId(id); |
|
|
|
history.setReason(isStaffAudition ? param.getAudition().getReason() : null); |
|
|
|
history.setStaffName(isStaffAudition ? param.getAudition().getStaffName() : null); |
|
|
|
IssueApplicationHistoryDTO history = new IssueApplicationHistoryDTO(); |
|
|
|
history.setActionType(defaultStatusUnderAuditing); |
|
|
|
history.setCreatedTime(param.getCreatedTime()); |
|
|
|
history.setCustomerId(param.getCustomerId()); |
|
|
|
history.setIssueApplicationId(id); |
|
|
|
history.setReason(isStaffAudition ? param.getAudition().getReason() : null); |
|
|
|
history.setStaffName(isStaffAudition ? param.getAudition().getStaffName() : null); |
|
|
|
|
|
|
|
historyService.save(history); |
|
|
|
if(!ifOpen){ |
|
|
|
historyService.save(history); |
|
|
|
if (!ifOpen) { |
|
|
|
IssueApplicationHistoryDTO repeatApplyRecord = new IssueApplicationHistoryDTO(); |
|
|
|
repeatApplyRecord.setActionType(ModuleConstants.ISSUE_APPLICATION_STATUS_UNDER_AUDITING); |
|
|
|
repeatApplyRecord.setCreatedTime(param.getCreatedTime()); |
|
|
@ -399,6 +403,7 @@ public class IssueServiceImpl extends BaseServiceImpl<IssueDao, IssueEntity> imp |
|
|
|
} |
|
|
|
}); |
|
|
|
|
|
|
|
} |
|
|
|
result.setIssueApplicationId(applyIds.iterator().next()); |
|
|
|
|
|
|
|
|
|
|
|