|
|
@@ -13,6 +13,7 @@ import com.ningdatech.basic.model.PageVo; |
|
|
|
import com.ningdatech.basic.util.CollUtils; |
|
|
|
import com.ningdatech.file.entity.File; |
|
|
|
import com.ningdatech.file.service.FileService; |
|
|
|
import com.ningdatech.pmapi.common.constant.BizConst; |
|
|
|
import com.ningdatech.pmapi.common.constant.CommonConst; |
|
|
|
import com.ningdatech.pmapi.common.constant.RegionConst; |
|
|
|
import com.ningdatech.pmapi.common.enumeration.CommonEnum; |
|
|
@@ -30,6 +31,12 @@ import com.ningdatech.pmapi.filemanage.service.INdProjectApplyBorrowService; |
|
|
|
import com.ningdatech.pmapi.organization.model.entity.DingOrganization; |
|
|
|
import com.ningdatech.pmapi.organization.service.IDingOrganizationService; |
|
|
|
import com.ningdatech.pmapi.projectdeclared.model.dto.DelayedApplyDTO; |
|
|
|
import com.ningdatech.pmapi.projectdeclared.model.entity.Contract; |
|
|
|
import com.ningdatech.pmapi.projectdeclared.model.entity.Purchase; |
|
|
|
import com.ningdatech.pmapi.projectdeclared.model.vo.ContractVO; |
|
|
|
import com.ningdatech.pmapi.projectdeclared.model.vo.PurchaseVO; |
|
|
|
import com.ningdatech.pmapi.projectdeclared.service.IContractService; |
|
|
|
import com.ningdatech.pmapi.projectdeclared.service.IPurchaseService; |
|
|
|
import com.ningdatech.pmapi.projectdeclared.utils.GenerateProjectCodeUtil; |
|
|
|
import com.ningdatech.pmapi.projectlib.enumeration.InstTypeEnum; |
|
|
|
import com.ningdatech.pmapi.projectlib.enumeration.ProjectStatusEnum; |
|
|
@@ -86,7 +93,9 @@ public class ProjectLibManage { |
|
|
|
private final INdProjectDelayApplyService projectDelayApplyService; |
|
|
|
private final INdProjectApplyBorrowService projectApplyBorrowService; |
|
|
|
private final IDingOrganizationService dingOrganizationService; |
|
|
|
private final UserInfoHelper userInfoHelper; |
|
|
|
private final IContractService contractService; |
|
|
|
|
|
|
|
private final IPurchaseService purchaseService; |
|
|
|
|
|
|
|
public PageVo<ProjectLibListItemVO> projectLibList(ProjectListReq req) { |
|
|
|
LambdaQueryWrapper<Project> query = ProjectHelper.projectQuery(req); |
|
|
@@ -500,7 +509,7 @@ public class ProjectLibManage { |
|
|
|
*/ |
|
|
|
public ProjectDetailVO getProjectDetail(Long projectId) { |
|
|
|
// 查询项目申报信息 |
|
|
|
Project projectInfo = projectService.getById(projectId); |
|
|
|
Project projectInfo = projectService.getNewProject(projectId); |
|
|
|
if (Objects.isNull(projectInfo)) { |
|
|
|
return null; |
|
|
|
} |
|
|
@@ -515,6 +524,22 @@ public class ProjectLibManage { |
|
|
|
ProjectHelper::convertVO) |
|
|
|
)); |
|
|
|
|
|
|
|
List<Long> allVersionProjectId = projectService.getAllVersionProjectId(projectInfo); |
|
|
|
//查询采购备案 |
|
|
|
Purchase purchase = purchaseService.getOne(Wrappers.lambdaQuery(Purchase.class) |
|
|
|
.in(Purchase::getProjectId, allVersionProjectId) |
|
|
|
.last(BizConst.LIMIT_1)); |
|
|
|
vo.setPurchase(BeanUtil.copyProperties(purchase, PurchaseVO.class)); |
|
|
|
|
|
|
|
//查询合同备案 |
|
|
|
Contract contract = contractService.getOne(Wrappers.lambdaQuery(Contract.class) |
|
|
|
.in(Contract::getProjectId, allVersionProjectId) |
|
|
|
.last(BizConst.LIMIT_1)); |
|
|
|
vo.setContract(BeanUtil.copyProperties(contract, ContractVO.class)); |
|
|
|
|
|
|
|
//查询初验信息 |
|
|
|
//查询终验信息 |
|
|
|
|
|
|
|
//查询年度投资金额 要是已验收的项目 |
|
|
|
if (ProjectStatusEnum.ACCEPTED.getCode().equals(projectInfo.getStatus())) { |
|
|
|
List<AnnualAmountVO> annualAmounts = Lists.newArrayList(); |
|
|
|