Browse Source

续建项目资金库

tags/24080901
PoffyZhang 1 year ago
parent
commit
a83ae487c0
1 changed files with 9 additions and 0 deletions
  1. +9
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/projectlib/manage/ProjectRenewalFundManage.java

+ 9
- 0
pmapi/src/main/java/com/ningdatech/pmapi/projectlib/manage/ProjectRenewalFundManage.java View File

@@ -25,6 +25,8 @@ import com.ningdatech.pmapi.projectlib.model.req.ProjectRenewalListReq;
import com.ningdatech.pmapi.projectlib.model.vo.ProjectRenewalFundDeclarationVO;
import com.ningdatech.pmapi.projectlib.service.IProjectRenewalFundDeclarationService;
import com.ningdatech.pmapi.projectlib.service.IProjectService;
import com.ningdatech.pmapi.user.security.auth.model.UserInfoDetails;
import com.ningdatech.pmapi.user.util.LoginUserUtil;
import com.wflow.exception.BusinessException;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.BeanUtils;
@@ -138,6 +140,10 @@ public class ProjectRenewalFundManage {
public Long audit(ProjectRenewalAuditReq param) {
Long projectRenewalId = param.getProjectRenewalId();
ProjectRenewalFundDeclaration projectRenewal = projectRenewalFundDeclarationService.getById(projectRenewalId);
VUtils.isTrue(Objects.isNull(projectRenewal)).throwMessage("该续建信息不存在!");
Project project = projectService.getNewProject(projectRenewal.getProjectId());

VUtils.isTrue(Objects.isNull(project)).throwMessage("关联的项目已经被删除!");
if (Boolean.TRUE.equals(param.getResult())){
projectRenewal.setApprovalStatus(ProjectRenewalApprovalStatusEnum.PASS.name());
}else {
@@ -148,6 +154,9 @@ public class ProjectRenewalFundManage {
projectRenewal.setAuditOpinion(auditOpinion);
projectRenewal.setApprovalStatus(ProjectRenewalApprovalStatusEnum.NOT_PASS.name());
}
projectRenewal.setRegionCode(project.getAreaCode());
projectRenewal.setOrgCode(project.getBuildOrgCode());
projectRenewal.setAuditOpinion(param.getAuditOpinion());
projectRenewal.setUpdateOn(LocalDateTime.now());
projectRenewalFundDeclarationService.updateById(projectRenewal);
return projectRenewal.getId();


Loading…
Cancel
Save