|
|
@ -862,17 +862,42 @@ public class ProjectServiceImpl extends BaseServiceImpl<ProjectDao, ProjectEntit |
|
|
|
} |
|
|
|
|
|
|
|
//2022-5-19 sun 需求完成时 来源事件管理的需求需要去修改事件数据 start
|
|
|
|
if ("ic_event".equals(projectEntity.getOrigin())) { |
|
|
|
//2022-10-11 如果项目来源于议题且议题来源于事件,也需要去回写...
|
|
|
|
modifyIcEvent(projectEntity,fromDTO.getUserId(),current); |
|
|
|
//2022-5-19 sun end
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* 事件-项目 |
|
|
|
* 事件-议题-项目 |
|
|
|
* 项目结案都需要回写事件 |
|
|
|
* 单独提出来方法 |
|
|
|
* @param projectEntity |
|
|
|
* @param userId |
|
|
|
* @param closeCaseTime 结案时间 |
|
|
|
*/ |
|
|
|
private void modifyIcEvent(ProjectEntity projectEntity,String userId,Date closeCaseTime) { |
|
|
|
boolean icEventFlag=false; |
|
|
|
if("issue".equals(projectEntity.getOrigin())){ |
|
|
|
List<String> issueIds =new ArrayList<>(); |
|
|
|
issueIds.add(projectEntity.getOrigin()); |
|
|
|
Result<List<IssueProfileDTO>> issueRes=govIssueOpenFeignClient.getIssueProfile(issueIds); |
|
|
|
if(issueRes.success()&&CollectionUtils.isNotEmpty(issueRes.getData())){ |
|
|
|
if("ic_event".equals(issueRes.getData().get(NumConstant.ZERO).getIssueSourceType())){ |
|
|
|
icEventFlag=true; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
if ("ic_event".equals(projectEntity.getOrigin())||icEventFlag) { |
|
|
|
ColseProjectOrDemandFormDTO dto = new ColseProjectOrDemandFormDTO(); |
|
|
|
dto.setCustomerId(fromDTO.getCustomerId()); |
|
|
|
dto.setUserId(fromDTO.getUserId()); |
|
|
|
dto.setCustomerId(projectEntity.getCustomerId()); |
|
|
|
dto.setUserId(projectEntity.getUpdatedBy()); |
|
|
|
dto.setIcEventId(projectEntity.getOriginId()); |
|
|
|
dto.setType("project"); |
|
|
|
dto.setCloseCaseTime(projectProcessEntity.getCreatedTime()); |
|
|
|
dto.setCloseCaseTime(closeCaseTime); |
|
|
|
icEventService.closeProjectOrDemand(dto); |
|
|
|
} |
|
|
|
//2022-5-19 sun end
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|