Commit b41051f4 authored by 侯彦文's avatar 侯彦文

删除合同内容

parent a7fd6e3f
package com.yonde.dcs.common.vo;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.yonde.dex.basedata.entity.annotation.DexEmbedded;
import com.yonde.dex.basedata.entity.annotation.ModelConfigProperty;
import com.yonde.dex.basedata.entity.annotation.ReferenceProperty;
import com.yonde.dex.basedata.entity.vo.DxIdVOEmbeddable;
import com.yonde.dex.basedata.entity.vo.IdOnlyVO;
import com.yonde.dex.basedata.entity.vo.IdVO;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import java.math.BigDecimal;
import java.util.Map;
/**
* @description:
* @version: 0
* @date: 2022-02-24 04:32:14
**/
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@JsonTypeInfo(
use = JsonTypeInfo.Id.CLASS,
property = "dxClassname",
defaultImpl = ExpectPayDetailsVO.class
)
@ModelConfigProperty(syncES = true)
public class ExpectPayDetailsVO extends IdOnlyVO implements IdVO {
/**
* dao扩展对象
*/
@DexEmbedded()
@JsonIgnore
private DxIdVOEmbeddable dxIdEmbeddable;
/**
* 金额
*/
private BigDecimal amount;
/**
* 收入合同
*/
@ReferenceProperty(baseProperty = "extIncomeContractId")
private ExtIncomeContractVO extIncomeContract;
/**
* 年份
*/
private String years;
/**
* extIncomeContract对应的属性
*/
private Long extIncomeContractId;
/**
* extIncomeContractId对应的类型
*/
private String extIncomeContractIdType;
private Map<String, Object> dynamicAttrs;
}
package com.yonde.dcs.common.vo;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.yonde.dex.basedata.entity.annotation.DexEmbedded;
import com.yonde.dex.basedata.entity.annotation.ModelConfigProperty;
import com.yonde.dex.basedata.entity.annotation.ReferenceProperty;
import com.yonde.dex.basedata.entity.vo.DxIdVOEmbeddable;
import com.yonde.dex.basedata.entity.vo.IdOnlyVO;
import com.yonde.dex.basedata.entity.vo.IdVO;
import com.yonde.dex.context.plugin.common.entity.DxContextVOEmbeddable;
import com.yonde.dex.context.plugin.common.entity.DxContextVOHolder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import java.math.BigDecimal;
import java.util.Map;
/**
* @description:
* @version: 1
* @date: 2022-02-24 03:07:53
**/
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@JsonTypeInfo(
use = JsonTypeInfo.Id.CLASS,
property = "dxClassname",
defaultImpl = ExtContractExpensesVO.class
)
@ModelConfigProperty(syncES = true)
public class ExtContractExpensesVO extends IdOnlyVO implements IdVO, DxContextVOHolder {
/**
* dao扩展对象
*/
@DexEmbedded()
@JsonIgnore
private DxIdVOEmbeddable dxIdEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxContextVOEmbeddable dxContextEmbeddable;
/**
* 收入合同
*/
@ReferenceProperty(baseProperty = "extIncomeContractId")
private ExtIncomeContractVO extIncomeContract;
/**
* extIncomeContract对应的属性
*/
private Long extIncomeContractId;
/**
* extIncomeContractId对应的类型
*/
private String extIncomeContractIdType;
/**
* 条目内容
*/
private String content;
/**
* 金额
*/
private BigDecimal itemAmount;
private Map<String, Object> dynamicAttrs;
}
package com.yonde.dcs.common.vo;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.yonde.dex.basedata.entity.annotation.DexEmbedded;
import com.yonde.dex.basedata.entity.annotation.ModelConfigProperty;
import com.yonde.dex.basedata.entity.annotation.ReferenceProperty;
import com.yonde.dex.basedata.entity.vo.DxIdVOEmbeddable;
import com.yonde.dex.basedata.entity.vo.IdOnlyVO;
import com.yonde.dex.basedata.entity.vo.IdVO;
import com.yonde.dex.linkdata.plugin.common.DxLinkDataVOEmbeddable;
import com.yonde.dex.linkdata.plugin.common.DxLinkDataVOHolder;
import com.yonde.dex.logicdelete.plugin.common.entity.DxLogicDeleteVOEmbeddable;
import com.yonde.dex.logicdelete.plugin.common.entity.DxLogicDeleteVOHolder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import java.util.Map;
/**
* @description:
* @version: 0
* @date: 2022-04-06 03:50:21
**/
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@JsonTypeInfo(
use = JsonTypeInfo.Id.CLASS,
property = "dxClassname",
defaultImpl = ExtContractLinkVO.class
)
@ModelConfigProperty(syncES = true)
public class ExtContractLinkVO extends IdOnlyVO implements IdVO,DxLinkDataVOHolder<ExtIncomeContractVO, ExtSpendingContractVO>, DxLogicDeleteVOHolder {
public static final String DX_ID_EMBEDDABLE_PROP_NAME = "dxIdEmbeddable";
public static final String DX_LOGIC_DELETE_EMBEDDABLE_PROP_NAME = "dxLogicDeleteEmbeddable";
public static final String DX_LINK_DATA_EMBEDDABLE_PROP_NAME = "dxLinkDataEmbeddable";
public static final String LINK_DESCRIPT_PROP_NAME = "linkDescript";
/**
* dao扩展对象
*/
@DexEmbedded()
@JsonIgnore
private DxIdVOEmbeddable dxIdEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxLogicDeleteVOEmbeddable dxLogicDeleteEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxLinkDataVOEmbeddable<ExtIncomeContractVO, ExtSpendingContractVO> dxLinkDataEmbeddable;
/**
* 支出合同
*/
@ReferenceProperty(baseProperty = "targetId")
private ExtSpendingContractVO target;
/**
* 收入合同
*/
@ReferenceProperty(baseProperty = "sourceId")
private ExtIncomeContractVO source;
/**
* target对应的属性
*/
private Long targetId;
/**
* targetId对应的类型
*/
private String targetIdType;
/**
* source对应的属性
*/
private Long sourceId;
/**
* sourceId对应的类型
*/
private String sourceIdType;
private Map<String, Object> dynamicAttrs;
}
package com.yonde.dcs.common.vo;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.yonde.dex.basedata.entity.annotation.DexEmbedded;
import com.yonde.dex.basedata.entity.annotation.ModelConfigProperty;
import com.yonde.dex.basedata.entity.annotation.ReferenceProperty;
import com.yonde.dex.basedata.entity.vo.DxIdVOEmbeddable;
import com.yonde.dex.basedata.entity.vo.IdOnlyVO;
import com.yonde.dex.basedata.entity.vo.IdVO;
import com.yonde.dex.context.plugin.common.entity.DxContextVOEmbeddable;
import com.yonde.dex.context.plugin.common.entity.DxContextVOHolder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import java.math.BigDecimal;
import java.util.Date;
import java.util.Map;
/**
* @description:
* @version: 3
* @date: 2022-02-24 03:26:09
**/
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@JsonTypeInfo(
use = JsonTypeInfo.Id.CLASS,
property = "dxClassname",
defaultImpl = ExtIncomeBillInfoVO.class
)
@ModelConfigProperty(syncES = true)
public class ExtIncomeBillInfoVO extends IdOnlyVO implements IdVO, DxContextVOHolder {
/**
* dao扩展对象
*/
@DexEmbedded()
@JsonIgnore
private DxIdVOEmbeddable dxIdEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxContextVOEmbeddable dxContextEmbeddable;
/**
* 收入明细
*/
@ReferenceProperty(baseProperty = "extIncomeDetailId")
private ExtIncomeDetailVO extIncomeDetail;
/**
* 票据号码
*/
private String ticketNumber;
/**
* 票据金额
*/
private BigDecimal ticketAmount;
/**
* 开具时间
*/
private Date issuingTime;
/**
* 税率
*/
private Float taxRate;
/**
* extIncomeDetail对应的属性
*/
private Long extIncomeDetailId;
/**
* extIncomeDetailId对应的类型
*/
private String extIncomeDetailIdType;
/**
* 票据类型
*/
private String billType;
private Map<String, Object> dynamicAttrs;
/**
* 备注
*/
private String remark;
}
package com.yonde.dcs.common.vo;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.yonde.dex.basedata.entity.annotation.DexEmbedded;
import com.yonde.dex.basedata.entity.annotation.ModelConfigProperty;
import com.yonde.dex.basedata.entity.annotation.RelationProperty;
import com.yonde.dex.basedata.entity.vo.DxIdVOEmbeddable;
import com.yonde.dex.basedata.entity.vo.IdOnlyVO;
import com.yonde.dex.context.plugin.common.entity.DxContextVOEmbeddable;
import com.yonde.dex.context.plugin.common.entity.DxContextVOHolder;
import com.yonde.dex.logicdelete.plugin.common.entity.DxLogicDeleteVOEmbeddable;
import com.yonde.dex.secretcode.plugin.common.entity.DxSecretVOEmbeddable;
import com.yonde.dex.secretcode.plugin.common.entity.DxSecretVOHolder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import java.util.Map;
/**
* @author: xfchai
* @description: 收入合同实体VO
* @version: 1
* @date: 2021-09-03 03:41:00
**/
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@JsonTypeInfo(
use = JsonTypeInfo.Id.CLASS,
property = "dxClassname",
defaultImpl = ExtIncomeContractVO.class
)
@ModelConfigProperty(syncES = true)
public class ExtIncomeContractVO extends IdOnlyVO implements DxSecretVOHolder, DxContextVOHolder {
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxContextVOEmbeddable dxContextEmbeddable;
/**
* dao扩展对象
*/
@DexEmbedded()
@JsonIgnore
private DxIdVOEmbeddable dxIdEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxLogicDeleteVOEmbeddable dxLogicDeleteEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxSecretVOEmbeddable dxSecretEmbeddable;
/**
* 项目属性
*/
private String itemProperties;
/**
* 项目名称
*/
private String itemName;
/**
* 项目来源
*/
private String itemOrigin;
/**
* 合同编号
*/
private String contractNo;
/**
* 合同名称
*/
private String contractName;
/**
* 合同生效时间
*/
private Date startTime;
/**
* 合同结束时间
*/
private Date endTime;
/**
* 校内科研代码
*/
private String researchCode;
/**
* 校内财务代码
*/
private String financialCode;
/**
* 执行财务规定
*/
private String financialRegul;
/**
* 合同价款类型
*/
private String contractPriceType;
/**
* 合同额
*/
private BigDecimal contractPrice;
/**
* 审价额
*/
private BigDecimal trialPrice;
/**
* 项目编号
*/
private String itemNumber;
/**
* 合同经费构成
*/
private String contractfunding;
/**
* 支付时间
*/
private Date payTime;
/**
* 支付金额
*/
private BigDecimal payPrice;
/**
* 到款情况
*/
private String paymentSituat;
/**
* 票据开具情况
*/
private String billStatus;
/**
* 票据开具时间
*/
private Date issuanceTime;
/**
* 票据号码
*/
private String billNumber;
/**
* 票据类型
*/
private String billType;
/**
* 税率
*/
private String tariff;
/**
* 票据金额
*/
private BigDecimal billAmount;
/**
* 收入明细集合
*/
@RelationProperty(refProperty = "extIncomeContract")
private List<ExtIncomeDetailVO> extIncomeDetails;
/**
* 合同经费条目构成集合
*/
@RelationProperty(refProperty = "extIncomeContract")
private List<ExtContractExpensesVO> contractExpensess;
/**
* 已到款
*/
private BigDecimal paid;
/**
* 预计到款明细集合
*/
@RelationProperty(refProperty = "extIncomeContract")
private List<ExpectPayDetailsVO> expectPayDetailss;
/**
* 到款明细集合
*/
@RelationProperty(refProperty = "extIncomeContract")
private List<ExtPaymentDetailsVO> paymentDetailss;
/**
* 待拨付
*/
private BigDecimal toBedisbursed;
private Map<String, Object> dynamicAttrs;
/**
* 合同link集合
*/
@RelationProperty(refProperty = "source")
private List<ExtContractLinkVO> sourceContractLink;
}
package com.yonde.dcs.common.vo;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.yonde.dex.basedata.entity.annotation.DexEmbedded;
import com.yonde.dex.basedata.entity.annotation.ModelConfigProperty;
import com.yonde.dex.basedata.entity.annotation.ReferenceProperty;
import com.yonde.dex.basedata.entity.annotation.RelationProperty;
import com.yonde.dex.basedata.entity.vo.DxIdVOEmbeddable;
import com.yonde.dex.basedata.entity.vo.IdOnlyVO;
import com.yonde.dex.basedata.entity.vo.IdVO;
import com.yonde.dex.context.plugin.common.entity.DxContextVOEmbeddable;
import com.yonde.dex.context.plugin.common.entity.DxContextVOHolder;
import com.yonde.dex.logicdelete.plugin.common.entity.DxLogicDeleteVOEmbeddable;
import com.yonde.dex.secretcode.plugin.common.entity.DxSecretVOEmbeddable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import java.util.Map;
/**
* @description:
* @version: 1
* @date: 2022-02-24 02:58:51
**/
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@JsonTypeInfo(
use = JsonTypeInfo.Id.CLASS,
property = "dxClassname",
defaultImpl = ExtIncomeDetailVO.class
)
@ModelConfigProperty(syncES = true)
public class ExtIncomeDetailVO extends IdOnlyVO implements IdVO, DxContextVOHolder {
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxContextVOEmbeddable dxContextEmbeddable;
/**
* dao扩展对象
*/
@DexEmbedded()
@JsonIgnore
private DxIdVOEmbeddable dxIdEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxLogicDeleteVOEmbeddable dxLogicDeleteEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxSecretVOEmbeddable dxSecretEmbeddable;
/**
* IncomeBillInfo集合
*/
@RelationProperty(refProperty = "extIncomeDetail")
private List<ExtIncomeBillInfoVO> IncomeBillInfos;
/**
* 收入合同
*/
@ReferenceProperty(baseProperty = "extIncomeContractId")
private ExtIncomeContractVO extIncomeContract;
/**
* 支付进度安排时间
*/
private Date payTime;
/**
* 到款情况
*/
private String paySituation;
/**
* 票据开具
*/
private String billing;
/**
* 支付进度安排金额
*/
private BigDecimal payAmount;
/**
* 到账时间
*/
private Date arrivalTime;
/**
* extIncomeContract对应的属性
*/
private Long extIncomeContractId;
/**
* extIncomeContractId对应的类型
*/
private String extIncomeContractIdType;
private Map<String, Object> dynamicAttrs;
/**
* 金额
*/
private BigDecimal amount;
/**
* 时间
*/
private Date incomeTime;
}
package com.yonde.dcs.common.vo;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.yonde.dcs.document.common.entity.vo.DxDocumentVO;
import com.yonde.dex.basedata.entity.annotation.DexEmbedded;
import com.yonde.dex.basedata.entity.annotation.ModelConfigProperty;
import com.yonde.dex.basedata.entity.annotation.ReferenceProperty;
import com.yonde.dex.basedata.entity.vo.DxIdVOEmbeddable;
import com.yonde.dex.basedata.entity.vo.IdOnlyVO;
import com.yonde.dex.basedata.entity.vo.IdVO;
import com.yonde.dex.linkdata.plugin.common.DxLinkDataVOEmbeddable;
import com.yonde.dex.linkdata.plugin.common.DxLinkDataVOHolder;
import com.yonde.dex.logicdelete.plugin.common.entity.DxLogicDeleteVOEmbeddable;
import com.yonde.dex.logicdelete.plugin.common.entity.DxLogicDeleteVOHolder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import java.math.BigDecimal;
import java.util.Map;
/**
* @description:
* @version: 0
* @date: 2022-02-24 04:30:52
**/
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@JsonTypeInfo(
use = JsonTypeInfo.Id.CLASS,
property = "dxClassname",
defaultImpl = ExtPaymentDetailsVO.class
)
@ModelConfigProperty(syncES = true)
public class ExtPaymentDetailsVO extends IdOnlyVO implements IdVO, DxLinkDataVOHolder<DxDocumentVO, DxDocumentVO>, DxLogicDeleteVOHolder {
/**
* dao扩展对象
*/
@DexEmbedded()
@JsonIgnore
private DxIdVOEmbeddable dxIdEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxLogicDeleteVOEmbeddable dxLogicDeleteEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxLinkDataVOEmbeddable<DxDocumentVO, DxDocumentVO> dxLinkDataEmbeddable;
/**
* 收入合同
*/
@ReferenceProperty(baseProperty = "extIncomeContractId")
private ExtIncomeContractVO extIncomeContract;
/**
* 年份
*/
private String years;
/**
* 金额
*/
private BigDecimal amount;
/**
* extIncomeContract对应的属性
*/
private Long extIncomeContractId;
/**
* extIncomeContractId对应的类型
*/
private String extIncomeContractIdType;
private Map<String, Object> dynamicAttrs;
}
package com.yonde.dcs.common.vo;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.yonde.dcs.document.common.entity.vo.DxDocumentVO;
import com.yonde.dcs.plan.common.vo.ExtSpendingDetailVO;
import com.yonde.dex.basedata.entity.annotation.DexEmbedded;
import com.yonde.dex.basedata.entity.annotation.ModelConfigProperty;
import com.yonde.dex.basedata.entity.annotation.RelationProperty;
import com.yonde.dex.basedata.entity.vo.DxIdVOEmbeddable;
import com.yonde.dex.basedata.entity.vo.IdOnlyVO;
import com.yonde.dex.basedata.entity.vo.IdVO;
import com.yonde.dex.context.plugin.common.entity.DxContextVOEmbeddable;
import com.yonde.dex.context.plugin.common.entity.DxContextVOHolder;
import com.yonde.dex.linkdata.plugin.common.DxLinkDataVOEmbeddable;
import com.yonde.dex.linkdata.plugin.common.DxLinkDataVOHolder;
import com.yonde.dex.logicdelete.plugin.common.entity.DxLogicDeleteVOEmbeddable;
import com.yonde.dex.logicdelete.plugin.common.entity.DxLogicDeleteVOHolder;
import com.yonde.dex.secretcode.plugin.common.entity.DxSecretVOEmbeddable;
import com.yonde.dex.secretcode.plugin.common.entity.DxSecretVOHolder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import java.util.Map;
/**
* @author: xfchai
* @description: 支出合同VO
* @version: 1
* @date: 2021-09-03 03:43:35
**/
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@JsonTypeInfo(
use = JsonTypeInfo.Id.CLASS,
property = "dxClassname",
defaultImpl = ExtSpendingContractVO.class
)
@ModelConfigProperty(syncES = true)
public class ExtSpendingContractVO extends IdOnlyVO implements IdVO , DxLinkDataVOHolder<DxDocumentVO, DxDocumentVO>, DxLogicDeleteVOHolder, DxSecretVOHolder, DxContextVOHolder {
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxContextVOEmbeddable dxContextEmbeddable;
/**
* dao扩展对象
*/
@DexEmbedded()
@JsonIgnore
private DxIdVOEmbeddable dxIdEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxLogicDeleteVOEmbeddable dxLogicDeleteEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxLinkDataVOEmbeddable<DxDocumentVO, DxDocumentVO> dxLinkDataEmbeddable;
/**
* 扩展VO属性
*/
@DexEmbedded()
@JsonIgnore
private DxSecretVOEmbeddable dxSecretEmbeddable;
/**
* 支出明细集合
*/
@RelationProperty(refProperty = "extSpendingContract")
private List<ExtSpendingDetailVO> extSpendingDetails;
/**
* 合同link集合
*/
@RelationProperty(refProperty = "target")
private List<ExtContractLinkVO> targetContractLink;
/**
* 合同编号
*/
private String contractNumber;
/**
* 审批日期
*/
private Date approvalDate;
/**
* 预计结算额
*/
private BigDecimal perSettleAmount;
/**
* 所属课题
*/
private String subject;
/**
* 合同成果
*/
private String contractOutcome;
/**
* 支付申请
*/
private String payApplication;
/**
* 已付金额
*/
private BigDecimal paidAmount;
/**
* 付款比例
*/
private String paymentRatio;
/**
* 费用大类
*/
private String expenseCategory;
/**
* 合同名称
*/
private String contractName;
/**
* 合作方
*/
private String partner;
/**
* 合同工期
*/
private Date contractDur;
/**
* 合同金额
*/
private BigDecimal contractAmount;
/**
* 技术负责人
*/
private String techLeader;
/**
* 合同内容
*/
private String contractContent;
/**
* 支付节点
*/
private String payNode;
/**
* 验收方法
*/
private String acceptMethod;
/**
* 未付金额
*/
private BigDecimal unpaidAmount;
/**
* 备注
*/
private String remark;
/**
* 费用小类
*/
private String feeSubCategory;
/**
* 结算额
*/
private BigDecimal settleAmount;
/**
* 收入合同编号
*/
private String revContractNo;
/**
* 签订部门
*/
private String signDepar;
/**
* 合同结束工期
*/
private Date contractEndDur;
private Map<String, Object> dynamicAttrs;
}
...@@ -3,7 +3,6 @@ package com.yonde.dcs.core.event; ...@@ -3,7 +3,6 @@ package com.yonde.dcs.core.event;
import cn.hutool.core.io.FileUtil; import cn.hutool.core.io.FileUtil;
import cn.hutool.extra.spring.SpringUtil; import cn.hutool.extra.spring.SpringUtil;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.yonde.dcs.common.vo.ExtIncomeDetailVO;
import com.yonde.dcs.common.vo.ExtInterfaceInfoLinkVO; import com.yonde.dcs.common.vo.ExtInterfaceInfoLinkVO;
import com.yonde.dcs.core.constants.Constants; import com.yonde.dcs.core.constants.Constants;
import com.yonde.dcs.core.factory.InternalInterfaceUtils; import com.yonde.dcs.core.factory.InternalInterfaceUtils;
...@@ -17,7 +16,6 @@ import com.yonde.dcs.core.word.ImportWordService; ...@@ -17,7 +16,6 @@ import com.yonde.dcs.core.word.ImportWordService;
import com.yonde.dcs.document.common.entity.vo.DxDocumentVO; import com.yonde.dcs.document.common.entity.vo.DxDocumentVO;
import com.yonde.dcs.document.core.service.DocumentService; import com.yonde.dcs.document.core.service.DocumentService;
import com.yonde.dcs.plan.common.vo.ExtSpendingDetailVO; import com.yonde.dcs.plan.common.vo.ExtSpendingDetailVO;
import com.yonde.dcs.plan.feign.ExtIncomeContractServiceFeign;
import com.yonde.dcs.plan.feign.ExtSpendingContractServiceFeign; import com.yonde.dcs.plan.feign.ExtSpendingContractServiceFeign;
import com.yonde.dex.basedata.entity.vo.IdVO; import com.yonde.dex.basedata.entity.vo.IdVO;
import com.yonde.dex.basedata.exception.DxBusinessException; import com.yonde.dex.basedata.exception.DxBusinessException;
...@@ -34,7 +32,6 @@ import lombok.extern.slf4j.Slf4j; ...@@ -34,7 +32,6 @@ import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections.CollectionUtils; import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang3.ObjectUtils; import org.apache.commons.lang3.ObjectUtils;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
...@@ -83,8 +80,7 @@ public class DocumentEvent { ...@@ -83,8 +80,7 @@ public class DocumentEvent {
@Autowired @Autowired
DocumentService documentService; DocumentService documentService;
@Autowired
private ExtIncomeContractServiceFeign extIncomeContractService;
@Autowired @Autowired
private ExtSpendingContractServiceFeign extSpendingContractService; private ExtSpendingContractServiceFeign extSpendingContractService;
@Autowired @Autowired
...@@ -291,39 +287,7 @@ public class DocumentEvent { ...@@ -291,39 +287,7 @@ public class DocumentEvent {
} }
@TransactionalEventListener(phase = TransactionPhase.AFTER_COMMIT)
public void afterCommit(BaseService.DataChangeEvent event) {
final String eventType = event.getEventType();
final BaseService.ChangeType changeType = BaseService.ChangeType.valueOf(eventType);
if (changeType == POST_CREATE || changeType == POST_UPDATE || changeType == BaseService.ChangeType.POST_DELETE) {
event.getEventTargets().forEach(t -> {
DxDocumentVO doc = new DxDocumentVO();
if (t instanceof ExtIncomeDetailVO) {
//刷新收入合同相关金额
ExtIncomeDetailVO extIncomeDetailVO = (ExtIncomeDetailVO) t;
this.refreshInContractAmount(extIncomeDetailVO.getExtIncomeContractId());
} else if (t instanceof ExtSpendingDetailVO) {
//刷新支出合同相关金额
ExtSpendingDetailVO spendingDetailVO = (ExtSpendingDetailVO) t;
this.refreshSpeContractAmount(spendingDetailVO.getExtSpendingContractId());
}
});
}
}
/**
* 刷新收入合同金额
*
* @param contractId
*/
private void refreshInContractAmount(Long contractId) {
//已到款
//待拨付
extIncomeContractService.calculateIncome(contractId);
//XXX年到款
extIncomeContractService.reCalculIncomeById(contractId);
}
/** /**
* 刷新支出合同金额 * 刷新支出合同金额
...@@ -337,26 +301,7 @@ public class DocumentEvent { ...@@ -337,26 +301,7 @@ public class DocumentEvent {
extSpendingContractService.calculateSpending(contractId); extSpendingContractService.calculateSpending(contractId);
} }
public void onEvent(BaseService.DataChangeEvent event) {
if (event.operationType.equals(POST_CREATE) || event.operationType.equals(POST_UPDATE)) {
extValidateSecret(event.eventTargets);
}
}
@Transactional(rollbackFor = {Exception.class, Error.class})
<P extends DxContextVOHolder & DxSecretVOHolder & IdVO> void extValidateSecret(Iterable<?> objects) {
for (Object data : objects) {
log.info(">>>>>extValidateSecret data:" + data);
log.info(">>>>>extValidateSecret data.getClass:" + data.getClass());
//校验项目中心相关对象密级和计划密级
if (data instanceof DxContextVOHolder && data instanceof DxSecretVOHolder && data instanceof IdVO) {
String checkResultStr = checkDxObjectSecret((P) data);
if (!StringUtils.isEmpty(checkResultStr)) {
throw new DxBusinessException("500", checkResultStr);
}
}
}
}
/** /**
* 校验计划、收入合同、支出合同密级与项目的关系 * 校验计划、收入合同、支出合同密级与项目的关系
......
package com.yonde.dcs.core.event; package com.yonde.dcs.core.event;
import com.yonde.dcs.common.vo.ExtIncomeContractVO;
import com.yonde.dcs.common.vo.ExtSpendingContractVO;
import com.yonde.dcs.plan.common.vo.ExtPlanVO;
import org.apache.commons.compress.utils.Lists;
import org.junit.Assert;
import org.junit.Test;
import org.junit.runner.RunWith; import org.junit.runner.RunWith;
import org.mockito.Mock; import org.mockito.Mock;
import org.springframework.test.context.junit4.SpringRunner; import org.springframework.test.context.junit4.SpringRunner;
import java.util.List;
//@SpringBootTest //@SpringBootTest
@RunWith(SpringRunner.class) @RunWith(SpringRunner.class)
public class DocumentEventTest { public class DocumentEventTest {
...@@ -20,20 +12,4 @@ public class DocumentEventTest { ...@@ -20,20 +12,4 @@ public class DocumentEventTest {
DocumentEvent documentEvent; DocumentEvent documentEvent;
@Test
public void extValidateSecretTest() {
ExtPlanVO extPlanVO = new ExtPlanVO();
ExtIncomeContractVO extIncomeContractVO = new ExtIncomeContractVO();
ExtSpendingContractVO extSpendingContractVO = new ExtSpendingContractVO();
List objects = Lists.newArrayList();
objects.add(extPlanVO);
objects.add(extIncomeContractVO);
objects.add(extSpendingContractVO);
documentEvent.extValidateSecret(objects);
Assert.assertNotNull("1");
}
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment