Ver código fonte

项目调整 自测完成

tags/24080901
PoffyZhang 1 ano atrás
pai
commit
dde6d5b093
1 arquivos alterados com 14 adições e 6 exclusões
  1. +14
    -6
      pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/manage/ProjectAdjustmentManage.java

+ 14
- 6
pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/manage/ProjectAdjustmentManage.java Ver arquivo

@@ -57,6 +57,19 @@ public class ProjectAdjustmentManage {
//项目名称去重
defaultDeclaredProjectManage.checkDuplication(projectDto);

//修改项目内容
if(!modifyProject(projectDto)){
throw new BusinessException("调整项目失败!");
}

//最后去重新 提交项目流程 不同的状态 提交到不同的工作流去
Function<DefaultDeclaredDTO, String> declaredFunction =
reStartProcessMapUtil.reStartProcessMap.get(projectInfo.getStatus());
VUtils.isTrue(Objects.isNull(declaredFunction)).throwMessage("状态不正常 没有找到对应申报函数!");
return declaredFunction.apply(dto);
}

private Boolean modifyProject(ProjectDTO projectDto) {
//先修改项目信息
Project project = new Project();
BeanUtils.copyProperties(projectDto,project);
@@ -78,11 +91,6 @@ public class ProjectAdjustmentManage {
}).collect(Collectors.toList());
projectApplicationService.saveBatch(applications);
}

//最后去重新 提交项目流程 不同的状态 提交到不同的工作流去
Function<DefaultDeclaredDTO, String> declaredFunction =
reStartProcessMapUtil.reStartProcessMap.get(projectInfo.getStatus());
VUtils.isTrue(Objects.isNull(declaredFunction)).throwMessage("状态不正常 没有找到对应申报函数!");
return declaredFunction.apply(dto);
return Boolean.TRUE;
}
}

Carregando…
Cancelar
Salvar