From 1d5c8b28be6339f0516239743ca1a3cda80aa00d Mon Sep 17 00:00:00 2001 From: WendyYang Date: Thu, 8 Aug 2024 14:22:14 +0800 Subject: [PATCH] =?UTF-8?q?modify:=201.=20=E9=A1=B9=E7=9B=AE=E5=8F=98?= =?UTF-8?q?=E6=9B=B4=E4=BF=AE=E6=94=B9=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/projectdeclared/model/dto/ContractDTO.java | 77 ---- .../projectdeclared/model/dto/EditContractDTO.java | 64 ++++ .../model/dto/EditOperationDTO.java | 75 ++++ .../projectdeclared/model/dto/EditProjectDTO.java | 393 +++++++++++++++++++++ .../model/dto/EditProjectDetailDTO.java | 33 ++ .../projectdeclared/model/dto/EditPurchaseDTO.java | 157 ++++++++ .../model/dto/EditPurchaseDetailDTO.java | 49 +++ .../projectdeclared/model/dto/OperationDTO.java | 96 ----- .../projectdeclared/model/dto/ProjectEditDTO.java | 37 -- .../api/projectdeclared/model/dto/PurchaseDTO.java | 179 ---------- .../projectdeclared/model/dto/PurchaseEditDTO.java | 47 --- .../projectlib/helper/ProjectChangeStopHelper.java | 26 +- .../api/projectlib/manage/ProjectChangeManage.java | 34 +- .../hz/pm/api/projectlib/model/dto/ProjectDTO.java | 2 - .../model/req/SubmitProjectChangeApplyReq.java | 6 +- .../projectlib/model/vo/ProjectChangeDetailVO.java | 4 +- 16 files changed, 806 insertions(+), 473 deletions(-) delete mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/ContractDTO.java create mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditContractDTO.java create mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditOperationDTO.java create mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditProjectDTO.java create mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditProjectDetailDTO.java create mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditPurchaseDTO.java create mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditPurchaseDetailDTO.java delete mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/OperationDTO.java delete mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/ProjectEditDTO.java delete mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/PurchaseDTO.java delete mode 100644 hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/PurchaseEditDTO.java diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/ContractDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/ContractDTO.java deleted file mode 100644 index 5f29a2e..0000000 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/ContractDTO.java +++ /dev/null @@ -1,77 +0,0 @@ -package com.hz.pm.api.projectdeclared.model.dto; - -import com.fasterxml.jackson.annotation.JsonFormat; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.math.BigDecimal; -import java.time.LocalDateTime; - -/** - * @Classname Contract - * @Description - * @Date 2023/5/30 15:35 - * @Author PoffyZhang - */ -@Data -@ApiModel(value = "ContractVO") -public class ContractDTO { - - @ApiModelProperty("主键") - private Long id; - - @ApiModelProperty("创建时间") - private LocalDateTime createOn; - - @ApiModelProperty("修改时间") - private LocalDateTime updateOn; - - @ApiModelProperty("合同名称") - private String name; - - @ApiModelProperty("合同总金额") - private BigDecimal totalAmount; - - @ApiModelProperty("供应商开户行") - private String supplierBank; - - @ApiModelProperty("供应商开户行帐号") - private String supplierAccount; - - @ApiModelProperty("质保期 年") - private Integer warrantyPeriod; - - @ApiModelProperty("质保金") - private BigDecimal retentionMoney; - - @ApiModelProperty("合同完成时间") - @JsonFormat(pattern = "yyyy-MM-dd") - private LocalDateTime contractTime; - - @ApiModelProperty("交货日期") - @JsonFormat(pattern = "yyyy-MM-dd") - private LocalDateTime deliveryTime; - - @ApiModelProperty("附件") - private String attachment; - - @ApiModelProperty("项目ID") - private Long projectId; - - @ApiModelProperty("项目编号") - private String projectCode; - - @ApiModelProperty("供应商联系人") - private String supplierContact; - - @ApiModelProperty("供应商联系方式") - private String supplierContactInfo; - - @ApiModelProperty("标段ID") - private Long bidId; - - @ApiModelProperty("合同编号") - private String constructionNo; - -} \ No newline at end of file diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditContractDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditContractDTO.java new file mode 100644 index 0000000..70d5b66 --- /dev/null +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditContractDTO.java @@ -0,0 +1,64 @@ +package com.hz.pm.api.projectdeclared.model.dto; + +import com.fasterxml.jackson.annotation.JsonFormat; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; +import java.time.LocalDateTime; + +/** + *

+ * 合同信息编辑 + *

+ * + * @author WendyYang + * @since 14:14 2024/8/8 + */ +@Data +@ApiModel(value = "ContractVO") +public class EditContractDTO { + + @ApiModelProperty("主键") + private Long id; + + @ApiModelProperty("合同名称") + private String name; + + @ApiModelProperty("合同总金额") + private BigDecimal totalAmount; + + @ApiModelProperty("供应商开户行") + private String supplierBank; + + @ApiModelProperty("供应商开户行帐号") + private String supplierAccount; + + @ApiModelProperty("质保期 年") + private Integer warrantyPeriod; + + @ApiModelProperty("质保金") + private BigDecimal retentionMoney; + + @ApiModelProperty("合同完成时间") + @JsonFormat(pattern = "yyyy-MM-dd") + private LocalDateTime contractTime; + + @ApiModelProperty("交货日期") + @JsonFormat(pattern = "yyyy-MM-dd") + private LocalDateTime deliveryTime; + + @ApiModelProperty("附件") + private String attachment; + + @ApiModelProperty("供应商联系人") + private String supplierContact; + + @ApiModelProperty("供应商联系方式") + private String supplierContactInfo; + + @ApiModelProperty("合同编号") + private String constructionNo; + +} \ No newline at end of file diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditOperationDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditOperationDTO.java new file mode 100644 index 0000000..0311669 --- /dev/null +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditOperationDTO.java @@ -0,0 +1,75 @@ +package com.hz.pm.api.projectdeclared.model.dto; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.time.LocalDateTime; + +/** + *

+ * 实施信息编辑实体类 + *

+ * + * @author WendyYang + * @since 09:28 2024/2/23 + */ +@Data +@ApiModel("实施对象") +public class EditOperationDTO { + + @ApiModelProperty("id") + private Long id; + + @ApiModelProperty("项目开工时间") + private LocalDateTime projectStartDate; + + @ApiModelProperty("初验时间") + private LocalDateTime initialInspectionDate; + + @ApiModelProperty("终验时间") + private LocalDateTime finalInspectionDate; + + @ApiModelProperty("试运行开始时间") + private LocalDateTime pilotRunStartDate; + + @ApiModelProperty("开始实施时间") + private LocalDateTime startTrialOperationDate; + + @ApiModelProperty("适配改造时间") + private LocalDateTime adaptationTime; + + @ApiModelProperty("系统自测时间") + private LocalDateTime selfTestTime; + + @ApiModelProperty("测试验证时间") + private LocalDateTime testValidTime; + + @ApiModelProperty("实际完成适配改造时间") + private LocalDateTime actualAdaptionTime; + + @ApiModelProperty("适配改造备注") + private String adaptionRemark; + + @ApiModelProperty("适配改造附件") + private String adaptionFiles; + + @ApiModelProperty("系统自测备注") + private String selfTestRemark; + + @ApiModelProperty("系统自测附件") + private String selfTestFiles; + + @ApiModelProperty("实际完成系统自测时间") + private LocalDateTime actualSelfTestTime; + + @ApiModelProperty("实际完成测试验证时间") + private LocalDateTime actualTestValidTime; + + @ApiModelProperty("测试验证备注") + private String testValidRemark; + + @ApiModelProperty("测试验证附件") + private String testValidFiles; + +} \ No newline at end of file diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditProjectDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditProjectDTO.java new file mode 100644 index 0000000..9f5d7be --- /dev/null +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditProjectDTO.java @@ -0,0 +1,393 @@ +package com.hz.pm.api.projectdeclared.model.dto; + +import com.fasterxml.jackson.annotation.JsonFormat; +import com.hz.pm.api.common.compare.Compare; +import com.hz.pm.api.projectlib.model.dto.GovSystemReplaceInfoDTO; +import com.hz.pm.api.projectlib.model.dto.ProjectApplicationDTO; +import com.hz.pm.api.projectlib.model.dto.ProjectPaymentPlanDTO; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; +import java.time.LocalDateTime; +import java.util.List; +import java.util.Map; + +/** + *

+ * 项目信息修改参数类 + *

+ * + * @author zpf + * @since 2023-02-03 + */ +@Data +public class EditProjectDTO { + + public static final String SYSTEM_REPLACE_INFOS = "systemReplaceInfos"; + + @ApiModelProperty("主键") + private Long id; + + @ApiModelProperty("所属地区编号") + private String areaCode; + + @ApiModelProperty("所属地区名称") + private String area; + + @ApiModelProperty("项目名称") + private String projectName; + + @ApiModelProperty("历年项目名称") + private String baseHistorProjName; + + @ApiModelProperty("'历年项目编码'") + private String baseHistorProjId; + + @ApiModelProperty("历年项目年度") + private String baseHistorProjYear; + + @ApiModelProperty("预算来源说明") + private String baseBasisAmountOri; + + @ApiModelProperty("是否临时增补 0:否 1:是") + private Integer isTemporaryAugment; + + @ApiModelProperty("项目负责人") + private String responsibleMan; + + @ApiModelProperty("负责人手机号码") + private String responsibleManMobile; + + @ApiModelProperty("项目联系人") + private String contactName; + + @ApiModelProperty("项目联系人手机号码") + private String contactPhone; + + @ApiModelProperty("建设单位名称") + private String buildOrgName; + + @ApiModelProperty("建设单位统一社会信用代码") + private String orgCreditCode; + + @ApiModelProperty("公司编码code") + private String buildOrgCode; + + @ApiModelProperty("建设单位浙政钉ID") + private String buildOrgZheJiangGovDingId; + + @ApiModelProperty("主管单位统一社会信用代码") + @Compare("主管单位统一社会信用代码") + private String superOrgCreditCode; + + @ApiModelProperty("项目类型 01:首次建设 02:迭代升级 03:结转建设 04新运维 05续运维") + @Compare("项目类型") + private String projectType; + + @ApiModelProperty("是否省级 1省级 2非省级") + private Integer baseProvManDeprtType; + + @ApiModelProperty("是否首次新建 0:否 1:是") + private Integer isFirst; + + @ApiModelProperty("项目预算年度") + private Integer projectYear; + + @ApiModelProperty("项目建设起始时间") + private String beginTime; + + @ApiModelProperty("项目建设终止时间") + private String endTime; + + @ApiModelProperty("四大体系 1:业务应用 2:应用支撑 3:数据资源 4:基础设施") + private Integer fourSystems; + + @ApiModelProperty("是否数字化改革项目 0:否 1:是") + private Integer isDigitalReform; + + @ApiModelProperty("综合业务领域 1: '党政机关整体智治',2: '数字政府',3: '数字经济',4: '数字社会',7: '数字文化',5: '数字法治',6: '一体化智能化公共数据平台', 8: '基层智治'") + private Integer bizDomain; + + @ApiModelProperty("建设层级 P省级 M市级 C县级 T乡镇级 V村级") + @Compare("建设层级") + private String buildLevel; + + @ApiModelProperty("贯通层级 P省级 M市级 C县级 T乡镇级 V村级") + @Compare("贯通层级") + private String lowestLevel; + + @ApiModelProperty("立项依据") + private String buildBasis; + + @ApiModelProperty("立项依据说明") + private String baseBasisEstablish; + + @ApiModelProperty("发改编码") + private String developCode; + + @ApiModelProperty("财政编码") + private String financialCode; + + @ApiModelProperty("是否上云 0:否 1:是") + private Integer isCloud; + + private String cloudType; + + @ApiModelProperty("等保级别 1:一级 2:二级 3:三级 4:四级 5:五级") + private Integer protectionLevel; + + @ApiModelProperty("是否密评 0:否 1:是") + private Integer isSecretComments; + + @ApiModelProperty("项目简介") + private String projectIntroduction; + + @ApiModelProperty("资金情况-申报-申报金额(总计)(万元)") + private BigDecimal declareAmount; + + @ApiModelProperty("资金情况-申报-自有金额(万元)") + private BigDecimal declareHaveAmount; + + @ApiModelProperty("资金情况-申报-政府投资-本级财政资金(万元)") + private BigDecimal declareGovOwnFinanceAmount; + + @ApiModelProperty("资金情况-申报-政府投资-上级补助资金(万元)") + private BigDecimal declareGovSuperiorFinanceAmount; + + @ApiModelProperty("申报-银行贷款(万元)") + private BigDecimal declareBankLendingAmount; + + @ApiModelProperty("申报-其它资金(万元)") + private BigDecimal declareOtherAmount; + + @ApiModelProperty("申报资金-分配情况-软件开发(万元)") + private BigDecimal declareSoftwareDevelopmentAmount; + + @ApiModelProperty("申报资金-分配情况-云资源、硬件购置(万元)") + private BigDecimal declareCloudHardwarePurchaseAmount; + + @ApiModelProperty("申报资金-分配情况-第三方服务(万元)") + private BigDecimal declareThirdPartyAmount; + + //================================================================================================================== + + @ApiModelProperty("资金分配情况-软件开发(万元)") + private BigDecimal softwareDevelopmentAmount; + + @ApiModelProperty("资金分配情况-云资源、硬件购置(万元)") + private BigDecimal cloudHardwarePurchaseAmount; + + @ApiModelProperty("资金分配情况-第三方服务(万元)") + private BigDecimal thirdPartyAmount; + + @ApiModelProperty("年度支付计划") + private List paymentPlanList; + + @ApiModelProperty("立项批复资金(万元)") + private BigDecimal approvalAmount; + + @ApiModelProperty("批复-自有金额(万元)") + @Compare("批复-自有金额") + private BigDecimal approvalHaveAmount; + + @ApiModelProperty("批复-政府投资-本级财政资金(万元)") + @Compare("批复-政府投资-本级财政资金") + private BigDecimal approvalGovOwnFinanceAmount; + + @ApiModelProperty("批复-政府投资-上级补助资金(万元)") + @Compare("批复-政府投资-上级补助资金") + private BigDecimal approvalGovSuperiorFinanceAmount; + + @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss") + private LocalDateTime annualPlanAddTime; + + @ApiModelProperty("核心业务-核心业务模块") + private String coreBusiness; + + @ApiModelProperty("安全投入-投入项") + private String safetyInputTitle; + + @ApiModelProperty("安全投入-内容描述") + private String safetyInputDescribe; + + @ApiModelProperty("安全投入-金额(万元)") + private BigDecimal safetyInputAmount; + + @ApiModelProperty("附件-初步方案") + private String preliminaryPlanFile; + + @ApiModelProperty("附件-佐证材料") + private String supportingMaterialsFile; + + @ApiModelProperty("附件-项目总投资测算明细") + private String calculationTotalInvestmentFile; + + @ApiModelProperty("附件-申报单位主要职责(单位三定方案)") + private String mainResponsibilitiesApplicantFile; + + @ApiModelProperty("备注") + private String projectRemarks; + + @ApiModelProperty("是否包含应用 0:否 1:是") + private Integer includeApplication; + + @ApiModelProperty("工程形象进度-第一季度") + private String engineeringSpeedOne; + + @ApiModelProperty("工程形象进度-第二季度") + private String engineeringSpeedTwo; + + @ApiModelProperty("工程形象进度-第三季度") + private String engineeringSpeedThree; + + @ApiModelProperty("工程形象进度-第四季度") + private String engineeringSpeedFour; + + @ApiModelProperty("核心业务-是否开启核心业务模块 false:关闭 true:开启") + private Boolean isOpenCoreBusiness; + + @ApiModelProperty("安全投入-是否开启安全投入模块 false:关闭 true:开启") + private Boolean isOpenSafetyInput; + + @ApiModelProperty("工程形象进度-是否开启 false:关闭 true:开启") + private Boolean isEngineeringSpeed; + + @ApiModelProperty("附件-是否开启 false:关闭 true:开启") + private Boolean isAccessories; + + @ApiModelProperty("备注-是否开启 false:关闭 true:开启") + private Boolean isRemarks; + + @ApiModelProperty("年度支付计划-是否开启 false:关闭 true:开启") + private Boolean isAnnualPlanAmount; + + @ApiModelProperty("一地创新全省共享项目-是否开启 false:关闭 true:开启") + private Boolean isInnovateWholeProvinceShare; + + @ApiModelProperty("安全投入-模块信息") + private String safetyInputModular; + + @ApiModelProperty("项目申报pdf") + private String projectPdf; + + @ApiModelProperty("立项申报pdf") + private String declarationPdf; + + @ApiModelProperty("建设周期(月)") + private String buildCycle; + + @ApiModelProperty("建设方案文件") + private String constructionPlanFile; + + @ApiModelProperty("立项批复文件") + private String approvedFile; + + @ApiModelProperty("批复金额") + private BigDecimal approvedTotalInvestmentIncrease; + + @ApiModelProperty("是否有上级条线主管部门 0没有 1有") + private Integer isHigherSuperOrg; + + @ApiModelProperty("上级主管部门") + private String higherSuperOrg; + + @ApiModelProperty("上级主管部门Code") + private String higherSuperOrgCode; + + @ApiModelProperty("是否有主管部门 0没有 1有") + private Integer isSuperOrg; + + @ApiModelProperty("主管部门名称") + private String superOrg; + + @ApiModelProperty("主管部门Code") + private String superOrgCode; + + @ApiModelProperty("前端所需验证字段") + private String allApplicationsDone; + + @ApiModelProperty("项目应用实例") + private List applicationList; + + @ApiModelProperty("流程状态") + private Integer processStatus; + + @ApiModelProperty("项目发起人 员工code") + private String sponsor; + + @ApiModelProperty("预审发起人 员工code") + private String preStartUserId; + + @ApiModelProperty("上级条线单位审核意见") + private String higherLineSuperOrgReviewComments; + + @ApiModelProperty("项目申报书") + private String projectApplicationForm; + + @ApiModelProperty("终验材料") + private String finalAcceptanceMaterials; + + private Map dynamicForm; + + //P省级,M市级,C县(市、区)级,T乡镇(街道、办事处)级,V村(社区)级 + private String baseLowestLevel; + + //01评审中;02待立项;03已驳回;04已立项;05已采购;06已初验;07已终验;00已终止 + private String baseProjSetProg; + + //P省级,M市级,C县(市、区)级,T乡镇(街道、办事处)级,V村(社区)级 + private String baseProjConsClass; + + //01政策、法规,02规划或决策部署,03上级下达任务,04领导批示,05单位核心业务或单位职能,00其他,多个时用中文;分割 + private String baseProjBasis; + + @ApiModelProperty("项目类型 01首次建设;02迭代升级;03结转建设;04新运维;05续运维") + private String baseProjType; + + @ApiModelProperty("是否退回|驳回的项目版本") + private Boolean isBackReject = Boolean.FALSE; + + @ApiModelProperty("可研报告") + private String baseResearchReportFile; + + @ApiModelProperty("可研批复文件") + private String baseResearchReportApprovalFile; + + @ApiModelProperty("其他附件") + private String baseProjOtherFile; + + @ApiModelProperty("项目内容与预期成效") + private String beseExpectedResults; + + @ApiModelProperty("内容类别") + private String baseConstructionType; + + @ApiModelProperty("咨询公司") + private String consultancy; + + @ApiModelProperty("是否开启评审清单") + private Boolean isReviewChecklist; + + @ApiModelProperty("评审清单") + private String reviewChecklist; + + @ApiModelProperty("是否推送省里") + private Boolean push; + + @ApiModelProperty("系统定位") + private String systemPosition; + + @ApiModelProperty("立项依据证明材料") + private String baseProjBasisFile; + + @ApiModelProperty("政务信息系统替代情况") + private List systemReplaceInfos; + + @ApiModelProperty("申报单位领域") + private Integer unitStrip; + + @ApiModelProperty("评审金额") + private BigDecimal reviewAmount; + +} diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditProjectDetailDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditProjectDetailDTO.java new file mode 100644 index 0000000..c80a956 --- /dev/null +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditProjectDetailDTO.java @@ -0,0 +1,33 @@ +package com.hz.pm.api.projectdeclared.model.dto; + +import com.hz.pm.api.projectdeclared.utils.BeanDiffUtil.FieldDiff; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.util.List; + +/** + *

+ * 项目信息编辑实体类 + *

+ * + * @author WendyYang + * @since 19:53 2024/8/5 + */ +@Data +public class EditProjectDetailDTO { + + public static final String FIELD_PROJECT = "project"; + + public static final String FIELD_PURCHASES = "purchases"; + + public static final String FIELD_PROJECT_DIFFS = "projectDiffs"; + + @ApiModelProperty("项目信息") + private EditProjectDTO project; + + private List projectDiffs; + + private List purchases; + +} diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditPurchaseDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditPurchaseDTO.java new file mode 100644 index 0000000..346dcab --- /dev/null +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditPurchaseDTO.java @@ -0,0 +1,157 @@ +package com.hz.pm.api.projectdeclared.model.dto; + +import com.fasterxml.jackson.annotation.JsonFormat; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.AllArgsConstructor; +import lombok.Data; + +import javax.validation.constraints.NotBlank; +import java.math.BigDecimal; +import java.time.LocalDate; +import java.time.LocalDateTime; + +/** + *

+ * 采购信息编辑实体类 + *

+ * + * @author WendyYang + * @since 14:14 2024/8/8 + */ +@Data +@ApiModel(value = "采购对象") +@AllArgsConstructor +public class EditPurchaseDTO { + + public static final String FIELD_ID = "id"; + + @ApiModelProperty("id") + private Long id; + + @ApiModelProperty("标段预算") + private BigDecimal bidBudget; + + @ApiModelProperty("标段名称") + private String bidName; + + @ApiModelProperty("标段类型") + private Integer bidType; + + @ApiModelProperty("供应商") + private String supplier; + + @ApiModelProperty("供应商联系人") + private String supplierContact; + + @ApiModelProperty("供应商联系方式") + private String supplierContactInfo; + + @ApiModelProperty("供应商社会信用代码") + private String supplierSocialCreditCode; + + @ApiModelProperty("采购方式 1公开招标 2自行采购") + private String purchaseMethod; + + @ApiModelProperty("成交金额") + private BigDecimal transactionAmount; + + @ApiModelProperty("成交时间") + private LocalDateTime transactionTime; + + @ApiModelProperty("代理机构") + private String agency; + + @ApiModelProperty("投标地址(政府采购网地址)") + private String bidAddress; + + @ApiModelProperty("开标时间") + private LocalDateTime bidStartTime; + + @ApiModelProperty("投标截止时间") + private LocalDateTime bidEndTime; + + @ApiModelProperty("代理机构社会统一信用代码") + private String purchaseSocialCreditCode; + + @ApiModelProperty("投标文件") + private String biddingDoc; + + @ApiModelProperty("招标文件") + private String bidDoc; + + @ApiModelProperty("中标通知书") + private String acceptanceLetter; + + @ApiModelProperty("预算执行确认书编号") + private String budgetExecConfirmNo; + + @ApiModelProperty("标段建设内容") + private String bidBuildContent; + + @ApiModelProperty("采购范围:1 公开采购、2 非公开采购") + private Integer purchaseScope; + + @ApiModelProperty("采购单位") + private String purchaseUnit; + + @ApiModelProperty("采购联系人") + private String purchaseContact; + + @ApiModelProperty("采购联系电话") + private String purchasePhone; + + @ApiModelProperty("采购联系地址") + private String purchaseConnectAddress; + + @ApiModelProperty("采购说明") + private String purchaseRemark; + + @ApiModelProperty("是否符合信创符合性要求") + private Boolean matchXcfhx; + + @ApiModelProperty("备注") + private String xcfhxApplyRemark; + + @ApiModelProperty("其他附件") + private String xcfhxApplyFiles; + + @ApiModelProperty("信创报告") + private String xcfhxReportFiles; + + @ApiModelProperty("信创符合性测评报告文件") + private String mhXcfhxReportFile; + + @ApiModelProperty("信创符合性测评记录ID") + private String mhXcfhxReportRecordId; + + @ApiModelProperty("初验材料") + private String preliminaryInspectionMaterials; + + @ApiModelProperty("初验 是否完成日志数据归集") + private Boolean isCompletedLogCollection; + + @ApiModelProperty("初验 实际成效指标") + private String actualPerformanceIndicators; + + @ApiModelProperty("终验申报材料") + private String finalInspectionMaterials; + + @ApiModelProperty("资源类型 1手动新增 2系统生成 3大数据局") + private Integer sourceType; + + @ApiModelProperty("项目名称") + private String projectName; + + @ApiModelProperty("标项支付金额") + private BigDecimal bidPayAmount; + + @ApiModelProperty("采购时间") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm") + private LocalDate purchaseDate; + + @ApiModelProperty("是否发布信创云图") + public Boolean publishMhNotice; + + +} diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditPurchaseDetailDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditPurchaseDetailDTO.java new file mode 100644 index 0000000..aa9f2d8 --- /dev/null +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/EditPurchaseDetailDTO.java @@ -0,0 +1,49 @@ +package com.hz.pm.api.projectdeclared.model.dto; + +import com.hz.pm.api.projectdeclared.utils.BeanDiffUtil.FieldDiff; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.util.List; + +/** + *

+ * PurchaseEditDTO + *

+ * + * @author WendyYang + * @since 11:12 2024/8/6 + */ +@Data +public class EditPurchaseDetailDTO { + + public static final String FIELD_PURCHASE = "purchase"; + + public static final String FIELD_CONTRACT = "contract"; + + public static final String FIELD_OPERATION = "operation"; + + public static final String FIELD_PURCHASE_DIFFS = "purchaseDiffs"; + + public static final String FIELD_CONTRACT_DIFFS = "contractDiffs"; + + public static final String FIELD_OPERATION_DIFFS = "operationDiffs"; + + //================================================================================================================== + + @ApiModelProperty("采购信息") + private EditPurchaseDTO purchase; + + private List purchaseDiffs; + + @ApiModelProperty("合同信息") + private EditContractDTO contract; + + private List contractDiffs; + + @ApiModelProperty("实施信息") + private EditOperationDTO operation; + + private List operationDiffs; + +} diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/OperationDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/OperationDTO.java deleted file mode 100644 index 8d4168e..0000000 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/OperationDTO.java +++ /dev/null @@ -1,96 +0,0 @@ -package com.hz.pm.api.projectdeclared.model.dto; - -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.time.LocalDateTime; - -/** - *

- * OperationVO - *

- * - * @author WendyYang - * @since 09:28 2024/2/23 - */ -@Data -@ApiModel("实施对象") -public class OperationDTO { - - @ApiModelProperty("id") - private Long id; - - @ApiModelProperty("项目ID") - private Long projectId; - - @ApiModelProperty("项目Code") - private String projectCode; - - @ApiModelProperty("创建时间") - private LocalDateTime createOn; - - @ApiModelProperty("修改时间") - private LocalDateTime updateOn; - - @ApiModelProperty("创建人 工号") - private String createBy; - - @ApiModelProperty("修改人 工号") - private String updateBy; - - @ApiModelProperty("项目开工时间") - private LocalDateTime projectStartDate; - - @ApiModelProperty("初验时间") - private LocalDateTime initialInspectionDate; - - @ApiModelProperty("终验时间") - private LocalDateTime finalInspectionDate; - - @ApiModelProperty("标段ID") - private Long bidId; - - @ApiModelProperty("试运行开始时间") - private LocalDateTime pilotRunStartDate; - - @ApiModelProperty("开始实施时间") - private LocalDateTime startTrialOperationDate; - - @ApiModelProperty("适配改造时间") - private LocalDateTime adaptationTime; - - @ApiModelProperty("系统自测时间") - private LocalDateTime selfTestTime; - - @ApiModelProperty("测试验证时间") - private LocalDateTime testValidTime; - - @ApiModelProperty("实际完成适配改造时间") - private LocalDateTime actualAdaptionTime; - - @ApiModelProperty("适配改造备注") - private String adaptionRemark; - - @ApiModelProperty("适配改造附件") - private String adaptionFiles; - - @ApiModelProperty("系统自测备注") - private String selfTestRemark; - - @ApiModelProperty("系统自测附件") - private String selfTestFiles; - - @ApiModelProperty("实际完成系统自测时间") - private LocalDateTime actualSelfTestTime; - - @ApiModelProperty("实际完成测试验证时间") - private LocalDateTime actualTestValidTime; - - @ApiModelProperty("测试验证备注") - private String testValidRemark; - - @ApiModelProperty("测试验证附件") - private String testValidFiles; - -} \ No newline at end of file diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/ProjectEditDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/ProjectEditDTO.java deleted file mode 100644 index 53f0a4e..0000000 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/ProjectEditDTO.java +++ /dev/null @@ -1,37 +0,0 @@ -package com.hz.pm.api.projectdeclared.model.dto; - -import com.hz.pm.api.projectdeclared.utils.BeanDiffUtil.FieldDiff; -import com.hz.pm.api.projectlib.model.dto.ProjectDTO; -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.io.Serializable; -import java.util.List; - -/** - *

- * ProjectDetailDTO - *

- * - * @author WendyYang - * @since 19:53 2024/8/5 - */ -@Data -public class ProjectEditDTO implements Serializable { - - private static final long serialVersionUID = 7066112975653039072L; - - public static final String FIELD_PROJECT = "project"; - - public static final String FIELD_PURCHASES = "purchases"; - - public static final String FIELD_PROJECT_DIFFS = "projectDiffs"; - - @ApiModelProperty("项目信息") - private ProjectDTO project; - - private List projectDiffs; - - private List purchases; - -} diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/PurchaseDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/PurchaseDTO.java deleted file mode 100644 index 2f25a80..0000000 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/PurchaseDTO.java +++ /dev/null @@ -1,179 +0,0 @@ -package com.hz.pm.api.projectdeclared.model.dto; - -import com.fasterxml.jackson.annotation.JsonFormat; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; -import lombok.AllArgsConstructor; -import lombok.Data; - -import javax.validation.constraints.NotBlank; -import java.math.BigDecimal; -import java.time.LocalDate; -import java.time.LocalDateTime; - -/** - * @Classname Purchase - * @Description - * @Date 2023/5/29 10:00 - * @Author PoffyZhang - */ -@Data -@ApiModel(value = "采购对象") -@AllArgsConstructor -public class PurchaseDTO { - - public static final String FIELD_ID = "id"; - - @ApiModelProperty("id") - private Long id; - - @ApiModelProperty("标段状态") - private Integer status; - - @ApiModelProperty("标段状态名称") - private String statusName; - - @ApiModelProperty("标段预算") - private BigDecimal bidBudget; - - @ApiModelProperty("标段名称") - private String bidName; - - @ApiModelProperty("标段类型") - private Integer bidType; - - @ApiModelProperty("项目ID") - private Long projectId; - - @ApiModelProperty("创建时间") - private LocalDateTime createOn; - - @ApiModelProperty("修改时间") - private LocalDateTime updateOn; - - @ApiModelProperty("创建人 工号") - private String createBy; - - @ApiModelProperty("修改人 工号") - private String updateBy; - - @ApiModelProperty("供应商") - private String supplier; - - @ApiModelProperty("供应商联系人") - private String supplierContact; - - @ApiModelProperty("供应商联系方式") - private String supplierContactInfo; - - @ApiModelProperty("供应商社会信用代码") - private String supplierSocialCreditCode; - - @ApiModelProperty("采购方式 1公开招标 2自行采购") - private String purchaseMethod; - - @ApiModelProperty("成交金额") - private BigDecimal transactionAmount; - - @ApiModelProperty("成交时间") - private LocalDateTime transactionTime; - - @ApiModelProperty("代理机构") - private String agency; - - @ApiModelProperty("投标地址(政府采购网地址)") - private String bidAddress; - - @ApiModelProperty("开标时间") - private LocalDateTime bidStartTime; - - @ApiModelProperty("投标截止时间") - private LocalDateTime bidEndTime; - - @ApiModelProperty("代理机构社会统一信用代码") - private String purchaseSocialCreditCode; - - @ApiModelProperty("投标文件") - private String biddingDoc; - - @ApiModelProperty("招标文件") - private String bidDoc; - - @ApiModelProperty("中标通知书") - private String acceptanceLetter; - - @ApiModelProperty("预算执行确认书编号") - private String budgetExecConfirmNo; - - @ApiModelProperty("标段建设内容") - private String bidBuildContent; - - @ApiModelProperty("采购范围:1 公开采购、2 非公开采购") - private Integer purchaseScope; - - @ApiModelProperty("采购单位") - private String purchaseUnit; - - @ApiModelProperty("采购联系人") - private String purchaseContact; - - @ApiModelProperty("采购联系电话") - private String purchasePhone; - - @ApiModelProperty("采购联系地址") - private String purchaseConnectAddress; - - @ApiModelProperty("采购说明") - private String purchaseRemark; - - @ApiModelProperty("是否符合信创符合性要求") - private Boolean matchXcfhx; - - @ApiModelProperty("备注") - private String xcfhxApplyRemark; - - @ApiModelProperty("其他附件") - private String xcfhxApplyFiles; - - @ApiModelProperty("信创报告") - private String xcfhxReportFiles; - - @ApiModelProperty("信创符合性测评报告文件") - @NotBlank(message = "信创符合性测评报告文件不能为空") - private String mhXcfhxReportFile; - - @ApiModelProperty("信创符合性测评记录ID") - @NotBlank(message = "信创符合性测评记录ID不能为空") - private String mhXcfhxReportRecordId; - - @ApiModelProperty("初验材料") - @NotBlank(message = "请提交初验材料") - private String preliminaryInspectionMaterials; - - @ApiModelProperty("初验 是否完成日志数据归集") - private Boolean isCompletedLogCollection; - - @ApiModelProperty("初验 实际成效指标") - private String actualPerformanceIndicators; - - @ApiModelProperty("终验申报材料") - private String finalInspectionMaterials; - - @ApiModelProperty("资源类型 1手动新增 2系统生成 3大数据局") - private Integer sourceType; - - @ApiModelProperty("项目名称") - private String projectName; - - @ApiModelProperty("标项支付金额") - private BigDecimal bidPayAmount; - - @ApiModelProperty("采购时间") - @JsonFormat(pattern = "yyyy-MM-dd HH:mm") - private LocalDate purchaseDate; - - @ApiModelProperty("是否发布信创云图") - public Boolean publishMhNotice; - - -} diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/PurchaseEditDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/PurchaseEditDTO.java deleted file mode 100644 index d6ca696..0000000 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/dto/PurchaseEditDTO.java +++ /dev/null @@ -1,47 +0,0 @@ -package com.hz.pm.api.projectdeclared.model.dto; - -import com.hz.pm.api.projectdeclared.utils.BeanDiffUtil.FieldDiff; -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.util.List; - -/** - *

- * PurchaseEditDTO - *

- * - * @author WendyYang - * @since 11:12 2024/8/6 - */ -@Data -public class PurchaseEditDTO { - - public static final String FIELD_PURCHASE = "purchase"; - - public static final String FIELD_CONTRACT = "contract"; - - public static final String FIELD_OPERATION = "operation"; - - public static final String FIELD_PURCHASE_DIFFS = "purchaseDiffs"; - - public static final String FIELD_CONTRACT_DIFFS = "contractDiffs"; - - public static final String FIELD_OPERATION_DIFFS = "operationDiffs"; - - @ApiModelProperty("采购信息") - private PurchaseDTO purchase; - - private List purchaseDiffs; - - @ApiModelProperty("合同信息") - private ContractDTO contract; - - private List contractDiffs; - - @ApiModelProperty("实施信息") - private OperationDTO operation; - - private List operationDiffs; - -} diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/helper/ProjectChangeStopHelper.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/helper/ProjectChangeStopHelper.java index b82bb28..0240d5d 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/helper/ProjectChangeStopHelper.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/helper/ProjectChangeStopHelper.java @@ -24,7 +24,7 @@ import com.hz.pm.api.projectdeclared.service.IPurchaseService; import com.hz.pm.api.projectdeclared.utils.BeanDiffUtil.FieldDiff; import com.hz.pm.api.projectlib.entity.PurchaseStatusChange; import com.hz.pm.api.projectlib.manage.ProjectLibManage; -import com.hz.pm.api.projectlib.model.dto.ProjectDTO; +import com.hz.pm.api.projectdeclared.model.dto.EditProjectDTO; import com.hz.pm.api.projectlib.model.entity.Project; import com.hz.pm.api.projectlib.model.entity.ProjectStatusChange; import com.hz.pm.api.projectlib.model.enumeration.status.*; @@ -148,7 +148,7 @@ public class ProjectChangeStopHelper { changeHistory.setStatus(buildBizStatus(projEvent).getCode()); projectChangeHistoryService.updateById(changeHistory); if (projEvent.equals(ProjectStateChangeEvent.CHANGE_APPLY_PASS)) { - projectEditRewrite(JSONUtil.toBean(changeHistory.getChangeContent(), ProjectEditDTO.class)); + projectEditRewrite(JSONUtil.toBean(changeHistory.getChangeContent(), EditProjectDetailDTO.class)); } } ProjectStatusChange change = projectStatusChangeService.getLastOne(projBeforeEvent, projectId); @@ -222,12 +222,12 @@ public class ProjectChangeStopHelper { return bizStatus; } - private void projectEditRewrite(ProjectEditDTO projectEdit) { + private void projectEditRewrite(EditProjectDetailDTO projectEdit) { List projectDiffs = projectEdit.getProjectDiffs(); if (CollUtil.isNotEmpty(projectDiffs)) { - ProjectDTO projectDetail = projectEdit.getProject(); + EditProjectDTO projectDetail = projectEdit.getProject(); FieldDiff systemReplaceInfos = CollUtil.findOne(projectDiffs, - w -> w.getFieldName().equals(ProjectDTO.SYSTEM_REPLACE_INFOS)); + w -> w.getFieldName().equals(EditProjectDTO.SYSTEM_REPLACE_INFOS)); if (systemReplaceInfos != null) { projectLibManage.saveGovSystemReplaceInfos(projectDetail.getId(), projectDetail.getProjectCode(), projectDetail.getSystemReplaceInfos()); @@ -238,9 +238,9 @@ public class ProjectChangeStopHelper { projectService.update(wrapper); } } - List purchases = projectEdit.getPurchases(); + List purchases = projectEdit.getPurchases(); if (CollUtil.isNotEmpty(purchases)) { - for (PurchaseEditDTO purchaseEdit : purchases) { + for (EditPurchaseDetailDTO purchaseEdit : purchases) { modifyPurchase(purchaseEdit); modifyContract(purchaseEdit); modifyOperation(purchaseEdit); @@ -248,10 +248,10 @@ public class ProjectChangeStopHelper { } } - private void modifyPurchase(PurchaseEditDTO purchaseEdit) { + private void modifyPurchase(EditPurchaseDetailDTO purchaseEdit) { List purchaseDiffs = purchaseEdit.getPurchaseDiffs(); if (CollUtil.isNotEmpty(purchaseDiffs)) { - PurchaseDTO purchaseDetail = purchaseEdit.getPurchase(); + EditPurchaseDTO purchaseDetail = purchaseEdit.getPurchase(); UpdateWrapper wrapper = buildWrapper(purchaseDiffs, Purchase.class); if (wrapper != null) { wrapper.eq("id", purchaseDetail.getId()); @@ -260,10 +260,10 @@ public class ProjectChangeStopHelper { } } - private void modifyContract(PurchaseEditDTO purchaseEdit) { + private void modifyContract(EditPurchaseDetailDTO purchaseEdit) { List contractDiffs = purchaseEdit.getContractDiffs(); if (CollUtil.isNotEmpty(contractDiffs)) { - ContractDTO contractDetail = purchaseEdit.getContract(); + EditContractDTO contractDetail = purchaseEdit.getContract(); UpdateWrapper wrapper = buildWrapper(contractDiffs, Contract.class); if (wrapper != null) { wrapper.eq("id", contractDetail.getId()); @@ -272,10 +272,10 @@ public class ProjectChangeStopHelper { } } - private void modifyOperation(PurchaseEditDTO purchaseEdit) { + private void modifyOperation(EditPurchaseDetailDTO purchaseEdit) { List operationDiffs = purchaseEdit.getOperationDiffs(); if (CollUtil.isNotEmpty(operationDiffs)) { - OperationDTO operationDetail = purchaseEdit.getOperation(); + EditOperationDTO operationDetail = purchaseEdit.getOperation(); UpdateWrapper wrapper = buildWrapper(operationDiffs, Operation.class); if (wrapper != null) { wrapper.eq("id", operationDetail.getId()); diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectChangeManage.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectChangeManage.java index 22f027e..712ce28 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectChangeManage.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectChangeManage.java @@ -8,7 +8,6 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.hz.pm.api.common.enumeration.ProjectProcessType; -import com.hz.pm.api.common.model.constant.BizConst; import com.hz.pm.api.external.model.enumeration.MhUnitStripEnum; import com.hz.pm.api.projectdeclared.entity.ProjectChangeHistory; import com.hz.pm.api.projectdeclared.manage.DeclaredProjectHelper; @@ -84,7 +83,7 @@ public class ProjectChangeManage { @Transactional(rollbackFor = Exception.class) public synchronized void submitProjectChangeApply(SubmitProjectChangeApplyReq req) { JSONObject projectEditDetail = req.getProjectEditDetail(); - JSONObject projJsonObj = projectEditDetail.getJSONObject(ProjectEditDTO.FIELD_PROJECT); + JSONObject projJsonObj = projectEditDetail.getJSONObject(EditProjectDetailDTO.FIELD_PROJECT); ProjectDTO reqProj = projJsonObj.toBean(ProjectDTO.class); Project project = projectService.getNewProject(reqProj.getId()); if (ProjectStatus.ON_CHANGE_APPLY.eq(project.getStatus()) || @@ -93,7 +92,8 @@ public class ProjectChangeManage { } ProjectDetailVO projDetailOld = projectLibManage.getProjectDetail(project); - List projDiffs = BeanDiffUtil.diffSameField(projDetailOld, projJsonObj, ProjectDTO.SYSTEM_REPLACE_INFOS); + List projDiffs = BeanDiffUtil.diffSameField(projDetailOld, projJsonObj, + ProjectDTO.SYSTEM_REPLACE_INFOS, "id", "projectCode", "stage", "status"); List systemReplaceInfos = reqProj.getSystemReplaceInfos(); List systemReplaceInfosOld = projDetailOld.getSystemReplaceInfos(); if (!CollUtil.isEqualList(systemReplaceInfos, systemReplaceInfosOld)) { @@ -104,29 +104,29 @@ public class ProjectChangeManage { .newValue(systemReplaceInfos) .build()); } - projJsonObj.set(ProjectEditDTO.FIELD_PROJECT_DIFFS, projDiffs); - List purchaseJsonObjs = projectEditDetail.getBeanList(ProjectEditDTO.FIELD_PURCHASES, JSONObject.class); + projJsonObj.set(EditProjectDetailDTO.FIELD_PROJECT_DIFFS, projDiffs); + List purchaseJsonObjs = projectEditDetail.getBeanList(EditProjectDetailDTO.FIELD_PURCHASES, JSONObject.class); if (CollUtil.isNotEmpty(purchaseJsonObjs)) { List purchaseDetails = projDetailOld.getPurchaseDetails(); if (purchaseDetails != null && !purchaseDetails.isEmpty()) { Map reqPurchaseMap = CollUtils.listToMap(purchaseJsonObjs, - w -> w.getJSONObject(PurchaseEditDTO.FIELD_PURCHASE).getLong(PurchaseDTO.FIELD_ID)); + w -> w.getJSONObject(EditPurchaseDetailDTO.FIELD_PURCHASE).getLong(EditPurchaseDTO.FIELD_ID)); for (PurchaseFullInfoVO purchaseDetail : purchaseDetails) { PurchaseVO purchase = purchaseDetail.getPurchase(); ContractVO contract = purchaseDetail.getConstruction(); OperationVO operation = purchaseDetail.getOperation(); JSONObject reqPurchaseDetail = reqPurchaseMap.get(purchase.getId()); - JSONObject reqPurchase = reqPurchaseDetail.getJSONObject(PurchaseEditDTO.FIELD_PURCHASE); - JSONObject reqOperation = reqPurchaseDetail.getJSONObject(PurchaseEditDTO.FIELD_OPERATION); - JSONObject reqContract = reqPurchaseDetail.getJSONObject(PurchaseEditDTO.FIELD_CONTRACT); - - List purchaseDiffs = BeanDiffUtil.diffSameField(purchase, reqPurchase); - List operationDiffs = BeanDiffUtil.diffSameField(operation, reqOperation); - List contractDiffs = BeanDiffUtil.diffSameField(contract, reqContract); - reqPurchaseDetail.set(PurchaseEditDTO.FIELD_PURCHASE_DIFFS, purchaseDiffs); - reqPurchaseDetail.set(PurchaseEditDTO.FIELD_CONTRACT_DIFFS, contractDiffs); - reqPurchaseDetail.set(PurchaseEditDTO.FIELD_OPERATION_DIFFS, operationDiffs); + JSONObject reqPurchase = reqPurchaseDetail.getJSONObject(EditPurchaseDetailDTO.FIELD_PURCHASE); + JSONObject reqOperation = reqPurchaseDetail.getJSONObject(EditPurchaseDetailDTO.FIELD_OPERATION); + JSONObject reqContract = reqPurchaseDetail.getJSONObject(EditPurchaseDetailDTO.FIELD_CONTRACT); + + List purchaseDiffs = BeanDiffUtil.diffSameField(purchase, reqPurchase, "id"); + List operationDiffs = BeanDiffUtil.diffSameField(operation, reqOperation, "id"); + List contractDiffs = BeanDiffUtil.diffSameField(contract, reqContract, "id"); + reqPurchaseDetail.set(EditPurchaseDetailDTO.FIELD_PURCHASE_DIFFS, purchaseDiffs); + reqPurchaseDetail.set(EditPurchaseDetailDTO.FIELD_CONTRACT_DIFFS, contractDiffs); + reqPurchaseDetail.set(EditPurchaseDetailDTO.FIELD_OPERATION_DIFFS, operationDiffs); } } } @@ -191,7 +191,7 @@ public class ProjectChangeManage { return null; } ProjectChangeDetailVO result = new ProjectChangeDetailVO(); - result.setProjectEditDetail(JSONUtil.toBean(changeHistory.getChangeContent(), ProjectEditDTO.class)); + result.setProjectEditDetail(JSONUtil.toBean(changeHistory.getChangeContent(), EditProjectDetailDTO.class)); result.setChangeReason(changeHistory.getChangeReason()); result.setCreateOn(changeHistory.getCreateOn()); return result; diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/dto/ProjectDTO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/dto/ProjectDTO.java index 66b66d7..143a812 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/dto/ProjectDTO.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/dto/ProjectDTO.java @@ -24,8 +24,6 @@ public class ProjectDTO implements Serializable { private static final long serialVersionUID = 632385496811481979L; - public static final String SYSTEM_REPLACE_INFOS = "systemReplaceInfos"; - @ApiModelProperty("主键") private Long id; diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/req/SubmitProjectChangeApplyReq.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/req/SubmitProjectChangeApplyReq.java index eebffa1..7fa7384 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/req/SubmitProjectChangeApplyReq.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/req/SubmitProjectChangeApplyReq.java @@ -2,7 +2,7 @@ package com.hz.pm.api.projectlib.model.req; import cn.hutool.core.bean.BeanUtil; import cn.hutool.json.JSONObject; -import com.hz.pm.api.projectdeclared.model.dto.ProjectEditDTO; +import com.hz.pm.api.projectdeclared.model.dto.EditProjectDetailDTO; import io.swagger.annotations.ApiModelProperty; import lombok.Data; @@ -26,8 +26,8 @@ public class SubmitProjectChangeApplyReq { @ApiModelProperty("项目信息") private JSONObject projectEditDetail; - public ProjectEditDTO getProjectDetail() { - return BeanUtil.toBean(projectEditDetail, ProjectEditDTO.class); + public EditProjectDetailDTO getProjectDetail() { + return BeanUtil.toBean(projectEditDetail, EditProjectDetailDTO.class); } } diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/vo/ProjectChangeDetailVO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/vo/ProjectChangeDetailVO.java index e133034..8efe1a8 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/vo/ProjectChangeDetailVO.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/vo/ProjectChangeDetailVO.java @@ -1,6 +1,6 @@ package com.hz.pm.api.projectlib.model.vo; -import com.hz.pm.api.projectdeclared.model.dto.ProjectEditDTO; +import com.hz.pm.api.projectdeclared.model.dto.EditProjectDetailDTO; import io.swagger.annotations.ApiModelProperty; import lombok.Data; @@ -21,7 +21,7 @@ public class ProjectChangeDetailVO { private String changeReason; @ApiModelProperty("变更内容") - private ProjectEditDTO projectEditDetail; + private EditProjectDetailDTO projectEditDetail; @ApiModelProperty("变更申请时间") private LocalDateTime createOn;