update [应收金额]替换为[待确收金额]
This commit is contained in:
+2
-2
@@ -28,11 +28,11 @@ public interface ProjectDetailService {
|
||||
*/
|
||||
List<PayCommonProject> queryProjectList(List<String> list);
|
||||
/**
|
||||
* @Description 获取变更应收金额之后的状态
|
||||
* @Description 获取变更待确收金额之后的状态
|
||||
* @Author lqt
|
||||
* @Date 2021/9/14
|
||||
* @Param projectId 项目id
|
||||
* @Param receivableAmount 应收金额
|
||||
* @Param receivableAmount 待确收金额
|
||||
* @Param needInvoice 需要发票
|
||||
* @Return
|
||||
* @Exception
|
||||
|
||||
+9
-9
@@ -358,13 +358,13 @@ public class ProjectDetailServiceImpl implements ProjectDetailService {
|
||||
if(Objects.isNull(payCommonProject.getPaidAmount())){
|
||||
payCommonProject.setPaidAmount(new BigDecimal("0.00"));
|
||||
}
|
||||
// 应收金额没有变更 && 验证来款方式没有变更
|
||||
// 待确收金额没有变更 && 验证来款方式没有变更
|
||||
if(receivableAmount.compareTo(payCommonProject.getReceivableAmount()) == 0 && needInvoice.equals(payCommonProject.getNeedInvoice())){
|
||||
return null;
|
||||
}
|
||||
// 验证应收金额不能小于实收金额
|
||||
// 验证待确收金额不能小于实收金额
|
||||
if(receivableAmount.compareTo(payCommonProject.getPaidAmount()) < 0){
|
||||
throw new JeroBootException("应收金额不能小于实收金额!");
|
||||
throw new JeroBootException("待确收金额不能小于实收金额!");
|
||||
}
|
||||
// 验证来款方式,有变更,按照变更处理
|
||||
if(!needInvoice.equals(payCommonProject.getNeedInvoice())){
|
||||
@@ -384,7 +384,7 @@ public class ProjectDetailServiceImpl implements ProjectDetailService {
|
||||
BigDecimal b = listPayMailBillProject.stream().map(PayMailBillProject::getInvoiceAmount).reduce(BigDecimal.ZERO,BigDecimal::add);
|
||||
invoice = invoice.add(b);
|
||||
if(receivableAmount.compareTo(invoice) < 0){
|
||||
throw new JeroBootException("应收金额不可小于实收金额,请先修改实际来款后再来修改!");
|
||||
throw new JeroBootException("待确收金额不可小于实收金额,请先修改实际来款后再来修改!");
|
||||
}
|
||||
List<String> list = listPayMailBillProject.stream().map(PayMailBillProject::getBillId).collect(Collectors.toList());
|
||||
LambdaQueryWrapper<PayMailBill> queryPayMailBill = new LambdaQueryWrapper<>();
|
||||
@@ -394,7 +394,7 @@ public class ProjectDetailServiceImpl implements ProjectDetailService {
|
||||
y = listPayMailBill.size();
|
||||
}
|
||||
// 到账
|
||||
// 应收金额 = 实收金额 = 1
|
||||
// 待确收金额 = 实收金额 = 1
|
||||
if(receivableAmount.compareTo(payCommonProject.getPaidAmount()) == 0){
|
||||
projectStatusVO.setInAccount(ProjectCommon.IN_ACCOUNT1);
|
||||
}
|
||||
@@ -402,7 +402,7 @@ public class ProjectDetailServiceImpl implements ProjectDetailService {
|
||||
if(payCommonProject.getPaidAmount().compareTo(new BigDecimal("0.00")) == 0){
|
||||
projectStatusVO.setInAccount(ProjectCommon.IN_ACCOUNT0);
|
||||
}
|
||||
// 0 < 实收金额 && 实收金额 < 应收金额 = 2
|
||||
// 0 < 实收金额 && 实收金额 < 待确收金额 = 2
|
||||
if(payCommonProject.getPaidAmount().compareTo(new BigDecimal("0.00")) > 0
|
||||
&& payCommonProject.getPaidAmount().compareTo(receivableAmount) < 0){
|
||||
projectStatusVO.setInAccount(ProjectCommon.IN_ACCOUNT2);
|
||||
@@ -412,7 +412,7 @@ public class ProjectDetailServiceImpl implements ProjectDetailService {
|
||||
if(Objects.equals(payCommonProject.getNeedInvoice(),ProjectCommon.NEED_INVOICE0)){
|
||||
projectStatusVO.setMakeInvoice(ProjectCommon.MAKE_INVOICE0);
|
||||
}else{
|
||||
// 开票金额 = 应收金额 = 1
|
||||
// 开票金额 = 待确收金额 = 1
|
||||
if(invoice.compareTo(receivableAmount) == 0 ){
|
||||
projectStatusVO.setMakeInvoice(ProjectCommon.MAKE_INVOICE1);
|
||||
}
|
||||
@@ -420,13 +420,13 @@ public class ProjectDetailServiceImpl implements ProjectDetailService {
|
||||
if(invoice.compareTo(new BigDecimal("0.00")) == 0){
|
||||
projectStatusVO.setMakeInvoice(ProjectCommon.MAKE_INVOICE0);
|
||||
}
|
||||
// 开票金额 > 0 && 开票金额 < 应收金额 = 2
|
||||
// 开票金额 > 0 && 开票金额 < 待确收金额 = 2
|
||||
if(invoice.compareTo(new BigDecimal("0.00")) > 0 && invoice.compareTo(payCommonProject.getReceivableAmount()) < 0){
|
||||
projectStatusVO.setMakeInvoice(ProjectCommon.MAKE_INVOICE2);
|
||||
}
|
||||
}
|
||||
// 邮寄
|
||||
// 开票金额 = 应收金额 && 邮寄次数 = 开票次数 = 1
|
||||
// 开票金额 = 待确收金额 && 邮寄次数 = 开票次数 = 1
|
||||
if(invoice.compareTo(receivableAmount) == 0 && c == y){
|
||||
projectStatusVO.setMail(ProjectCommon.MAIL1);
|
||||
}
|
||||
|
||||
@@ -24,9 +24,9 @@ public class ProjectDetailVO implements Serializable {
|
||||
@ApiModelProperty(value = "项目类型")
|
||||
private Integer projectType;
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal receivableAmount;
|
||||
/**
|
||||
|
||||
+2
-2
@@ -663,7 +663,7 @@ public class PayIncomeContractController extends JeroController<PayIncomeContrac
|
||||
}
|
||||
//已收金额
|
||||
BigDecimal amountReceived = payIncomeContractDetailOutput.getAmountReceived();
|
||||
//应收金额
|
||||
//待确收金额
|
||||
BigDecimal accountsReceivableAmount = payIncomeContractDetailOutput.getAccountsReceivableAmount();
|
||||
//相减得到未收金额
|
||||
BigDecimal outstandingAmount = accountsReceivableAmount.subtract(amountReceived);
|
||||
@@ -797,7 +797,7 @@ public class PayIncomeContractController extends JeroController<PayIncomeContrac
|
||||
filedsList.add(new ExcelExportEntity("合同签订日期", "contractDate"));
|
||||
filedsList.add(new ExcelExportEntity("合同终止日期", "terminationDate"));
|
||||
filedsList.add(new ExcelExportEntity("合同约定主要时点", "contractTimePoints"));
|
||||
filedsList.add(new ExcelExportEntity("应收金额", "accountsReceivableAmount"));
|
||||
filedsList.add(new ExcelExportEntity("待确收金额", "accountsReceivableAmount"));
|
||||
filedsList.add(new ExcelExportEntity("已收金额", "amountReceived"));
|
||||
filedsList.add(new ExcelExportEntity("未收金额", "outstandingAmount"));
|
||||
filedsList.add(new ExcelExportEntity("账款状态", "accountStatus"));
|
||||
|
||||
+5
-5
@@ -140,11 +140,11 @@ public class PayIncomeContract implements Serializable {
|
||||
@ApiModelProperty(value = "合同约定主要时点")
|
||||
@Size(max = 200, message = "合同约定主要时点不能大于200个字符")
|
||||
private java.lang.String contractTimePoints;
|
||||
/**应收金额*/
|
||||
@Excel(name = "应收金额", width = 15)
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@NotNull(message = "应收金额不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "应收金额格式错误")
|
||||
/**待确收金额*/
|
||||
@Excel(name = "待确收金额", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@NotNull(message = "待确收金额不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "待确收金额格式错误")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal accountsReceivableAmount;
|
||||
/**已收金额*/
|
||||
|
||||
+3
-3
@@ -58,9 +58,9 @@ public class PayIncomeContractAssociatedCancellation implements Serializable {
|
||||
@Excel(name = "来款单位", width = 15)
|
||||
@ApiModelProperty(value = "来款单位")
|
||||
private java.lang.String chargeCompanyName;
|
||||
/**应收金额(元)*/
|
||||
@Excel(name = "应收金额(元)", width = 15)
|
||||
@ApiModelProperty(value = "应收金额(元)")
|
||||
/**待确收金额(元)*/
|
||||
@Excel(name = "待确收金额(元)", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额(元)")
|
||||
private java.math.BigDecimal receivableAmount;
|
||||
/**实收金额(元)*/
|
||||
@Excel(name = "实收金额(元)", width = 15)
|
||||
|
||||
+5
-5
@@ -47,11 +47,11 @@ public class PayIncomeContractInstallment implements Serializable {
|
||||
@NotEmpty(message = "阶段不能为空")
|
||||
@Size(max = 50, message = "阶段长度不能大于50个字符")
|
||||
private java.lang.String phaseName;
|
||||
/**应收金额*/
|
||||
@Excel(name = "应收金额", width = 15)
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@NotNull(message = "应收金额不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "应收金额格式错误")
|
||||
/**待确收金额*/
|
||||
@Excel(name = "待确收金额", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@NotNull(message = "待确收金额不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "待确收金额格式错误")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal accountsReceivableAmount;
|
||||
/**应收时间*/
|
||||
|
||||
+5
-5
@@ -144,12 +144,12 @@ public class PaySpendingContract implements Serializable {
|
||||
@ApiModelProperty(value = "合同约定主要时点")
|
||||
@Size(max = 200, message = "合同约定主要时点不能大于200个字符")
|
||||
private String contractTimePoints;
|
||||
/**应收金额*/
|
||||
@Excel(name = "应收金额", width = 15)
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@NotNull(message = "应收金额不能为空")
|
||||
/**待确收金额*/
|
||||
@Excel(name = "待确收金额", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@NotNull(message = "待确收金额不能为空")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
@DecimalMax(value = "9999999999.99",message = "应收金额格式错误")
|
||||
@DecimalMax(value = "9999999999.99",message = "待确收金额格式错误")
|
||||
private BigDecimal accountsReceivableAmount;
|
||||
/**已收金额*/
|
||||
@Excel(name = "已收金额", width = 15)
|
||||
|
||||
+3
-3
@@ -47,9 +47,9 @@ public class PaySpendingContractInstallment implements Serializable {
|
||||
@NotEmpty(message = "阶段不能为空")
|
||||
@Size(max = 50, message = "阶段长度不能大于50个字符")
|
||||
private String phaseName;
|
||||
/**应收金额*/
|
||||
@Excel(name = "阶段应收金额", width = 15)
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
/**待确收金额*/
|
||||
@Excel(name = "阶段待确收金额", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@NotNull(message = "阶段应收不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "阶段应收格式错误")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
|
||||
+3
-3
@@ -146,7 +146,7 @@ public class PayIncomeContractServiceImpl extends ServiceImpl<PayIncomeContractM
|
||||
}
|
||||
// if(!Objects.isNull(payIncomeContract.getAccountsReceivableAmount()) && !Objects.isNull(payIncomeContract.getAmountReceived())
|
||||
// && payIncomeContract.getAccountsReceivableAmount().compareTo(payIncomeContract.getAmountReceived()) < 0){
|
||||
// throw new JeroBootException("已收金额大于应收金额!");
|
||||
// throw new JeroBootException("已收金额大于待确收金额!");
|
||||
// }
|
||||
StringBuilder msgPayIncomeContract = ValidUtil.validateAll(payIncomeContract);
|
||||
if(!StringUtils.isBlank(msgPayIncomeContract)){
|
||||
@@ -237,7 +237,7 @@ public class PayIncomeContractServiceImpl extends ServiceImpl<PayIncomeContractM
|
||||
}
|
||||
if(!Objects.isNull(p.getAccountsReceivableAmount()) && !Objects.isNull(p.getPaidAmount())
|
||||
&& p.getAccountsReceivableAmount().compareTo(p.getPaidAmount()) < 0){
|
||||
msgPayIncomeContractInstallment.append("第").append(listPayIncomeContractInstallment.indexOf(p) + 1).append("期实收金额大于应收金额!");
|
||||
msgPayIncomeContractInstallment.append("第").append(listPayIncomeContractInstallment.indexOf(p) + 1).append("期实收金额大于待确收金额!");
|
||||
}
|
||||
});
|
||||
if(!StringUtils.isBlank(msgPayIncomeContractInstallment)){
|
||||
@@ -259,7 +259,7 @@ public class PayIncomeContractServiceImpl extends ServiceImpl<PayIncomeContractM
|
||||
}
|
||||
// if(!Objects.isNull(payIncomeContract.getAccountsReceivableAmount()) && !Objects.isNull(payIncomeContract.getAmountReceived())
|
||||
// && payIncomeContract.getAccountsReceivableAmount().compareTo(payIncomeContract.getAmountReceived()) < 0){
|
||||
// throw new JeroBootException("已收金额大于应收金额!");
|
||||
// throw new JeroBootException("已收金额大于待确收金额!");
|
||||
// }
|
||||
StringBuilder msgPayIncomeContract = ValidUtil.validateAll(payIncomeContract);
|
||||
if(!StringUtils.isBlank(msgPayIncomeContract)){
|
||||
|
||||
@@ -53,9 +53,9 @@ public class ProjectOutput implements Serializable {
|
||||
@ApiModelProperty(value = "来款单位")
|
||||
private String chargeCompanyName;
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal receivableAmount;
|
||||
/**
|
||||
|
||||
@@ -6,7 +6,7 @@ package com.jero.mail.commont;
|
||||
*/
|
||||
public interface constant {
|
||||
/**
|
||||
* 邮寄状态标识√,应收金额等于开票金额,开票次数等于邮寄次数。
|
||||
* 邮寄状态标识√,待确收金额等于开票金额,开票次数等于邮寄次数。
|
||||
*/
|
||||
public static final int ONE=1;
|
||||
/**
|
||||
|
||||
+1
-1
@@ -385,7 +385,7 @@ public class PayMailBillController extends JeroController<PayMailBill, IPayMailB
|
||||
List<PayMailBill> listPayMailBill = payMailBillService.list(queryPayMailBill);
|
||||
y = listPayMailBill.size();
|
||||
}
|
||||
//获取项目应收金额
|
||||
//获取项目待确收金额
|
||||
BigDecimal receivableAmount = new BigDecimal("0.00");
|
||||
|
||||
String project = "";
|
||||
|
||||
+2
-2
@@ -793,7 +793,7 @@ public class PayMailBillServiceImpl extends ServiceImpl<PayMailBillMapper, PayMa
|
||||
StringBuilder projectName,StringBuilder chargeCompanyName,StringBuilder principalName,StringBuilder principalId,
|
||||
int i) {
|
||||
int makeInvoice=4;
|
||||
BigDecimal amountReceivable=new BigDecimal("0");//应收金额
|
||||
BigDecimal amountReceivable=new BigDecimal("0");//待确收金额
|
||||
Integer needInvoice = 0;//是否需要发票
|
||||
BigDecimal invoiceAmount=payMailBillProject.getInvoiceAmount();//本次开票金额
|
||||
if(invoiceAmount ==null){
|
||||
@@ -1126,7 +1126,7 @@ public class PayMailBillServiceImpl extends ServiceImpl<PayMailBillMapper, PayMa
|
||||
private String editCheckCompanyProject(PayMailBillVO bm,PayMailBillProject oldBmp) {
|
||||
|
||||
int makeInvoice=4;
|
||||
BigDecimal amountReceivable=new BigDecimal("0");//应收金额
|
||||
BigDecimal amountReceivable=new BigDecimal("0");//待确收金额
|
||||
Integer needInvoice = 0;//是否需要发票
|
||||
|
||||
//之前开票总额-编辑之前的开票金额=原始开票总额
|
||||
|
||||
+2
-2
@@ -314,9 +314,9 @@ public class PayMeetingSituation implements Serializable {
|
||||
private Integer newContact;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal amountReceivable;
|
||||
|
||||
|
||||
+2
-2
@@ -660,7 +660,7 @@ public class PayMeetingSituationServiceImpl extends ServiceImpl<PayMeetingSituat
|
||||
throw new JeroBootException("合并开票只能是同一企业");
|
||||
}
|
||||
if (amountReceivable.compareTo(new BigDecimal("0")) == 0) {
|
||||
throw new JeroBootException("应收金额为0,不能合并开票");
|
||||
throw new JeroBootException("待确收金额为0,不能合并开票");
|
||||
}
|
||||
if (MeetingSubitemCommon.PAY_MODE_3.equals(payMeetingSituation1.getPayMode())) {
|
||||
throw new JeroBootException("缴费方式为打包,不能合并开票");
|
||||
@@ -1256,7 +1256,7 @@ public class PayMeetingSituationServiceImpl extends ServiceImpl<PayMeetingSituat
|
||||
payMeetingSituation1.setNoTaxAmount(payMeetingSituation.getNoTaxAmount());
|
||||
payMeetingSituation1.setTax(payMeetingSituation.getTax());
|
||||
}
|
||||
//如果是编辑可以更新应收金额
|
||||
//如果是编辑可以更新待确收金额
|
||||
if (payMeetingSituation.getId() != null){
|
||||
payMeetingSituation1.setAmountReceivable(payMeetingSituation.getAmountReceivable());
|
||||
}
|
||||
|
||||
@@ -85,9 +85,9 @@ public class MeetingEntity implements Serializable {
|
||||
private Integer identity;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
private BigDecimal amountReceivable;
|
||||
|
||||
/**
|
||||
|
||||
+2
-2
@@ -265,9 +265,9 @@ public class MeetingSituationContractVO {
|
||||
private Integer newContact;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal amountReceivable;
|
||||
|
||||
|
||||
+2
-2
@@ -277,9 +277,9 @@ public class PayMeetingSituationVO {
|
||||
private String paymentRecord;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal amountReceivable;
|
||||
|
||||
|
||||
+2
-2
@@ -69,9 +69,9 @@ public class StandardsSituationExcel extends SituationBaseExcel {
|
||||
private String postCode;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@Excel(name = "应收金额", width = 15)
|
||||
@Excel(name = "待确收金额", width = 15)
|
||||
private BigDecimal amountReceivable;
|
||||
|
||||
/**缴费方式*/
|
||||
|
||||
+1
-1
@@ -283,7 +283,7 @@ public class PayMemberProjectSubitemController extends JeroController<PayMemberP
|
||||
projectSubitemExcel.setProjectId(projectId);
|
||||
PayMemberProjectSubitem projectSubitem = new PayMemberProjectSubitem();
|
||||
errorMessage.addAll(ValidUtil.validateReturnListWithNum(projectSubitemExcel,errorRowNum));
|
||||
//应收金额
|
||||
//待确收金额
|
||||
String amountReceivable = projectSubitemExcel.getAmountReceivable();
|
||||
if (errorMessage.isEmpty()) {
|
||||
projectSubitem.setAmountReceivable(new BigDecimal(amountReceivable));
|
||||
|
||||
+5
-5
@@ -164,13 +164,13 @@ public class PayMemberProjectSubitem implements Serializable {
|
||||
private String postContactName;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@Excel(name = "应收金额", width = 15,orderNum = "8")
|
||||
@Excel(name = "待确收金额", width = 15,orderNum = "8")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@NotNull(message = "应收金额不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "应收金额格式错误")
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@NotNull(message = "待确收金额不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "待确收金额格式错误")
|
||||
private BigDecimal amountReceivable;
|
||||
|
||||
/**
|
||||
|
||||
+4
-4
@@ -194,11 +194,11 @@ public class TbCertificatePayment implements Serializable {
|
||||
private String certificateId;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@Excel(name = "应收金额", width = 15)
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@DecimalMax(value = "9999999999.99", message = "应收金额格式错误")
|
||||
@Excel(name = "待确收金额", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@DecimalMax(value = "9999999999.99", message = "待确收金额格式错误")
|
||||
private BigDecimal amountReceivable;
|
||||
|
||||
/**
|
||||
|
||||
+5
-5
@@ -129,12 +129,12 @@ public class TbMemberProjectSubitem implements Serializable {
|
||||
private java.util.Date registerTime;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@Excel(name = "应收金额", width = 15)
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@NotNull(message = "应收金额不能为空")
|
||||
@DecimalMax(value = "9999999999.99", message = "应收金额格式错误")
|
||||
@Excel(name = "待确收金额", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@NotNull(message = "待确收金额不能为空")
|
||||
@DecimalMax(value = "9999999999.99", message = "待确收金额格式错误")
|
||||
private BigDecimal amountReceivable;
|
||||
|
||||
/**
|
||||
|
||||
+2
-2
@@ -141,7 +141,7 @@ public class PayPayMemberProjectSubitemServiceImpl extends ServiceImpl<PayMember
|
||||
paySendContactsMessageDTO.setPhone(payContactsManagement.getPhone());
|
||||
paySendContactsMessageDTO.setUserId(memberProject.getDirectorId());
|
||||
paySendContactsMessageDTO.setFlag(ProjectCommon.FLAG0);
|
||||
// 项目的应收金额>0 发送缴费通知
|
||||
// 项目的待确收金额>0 发送缴费通知
|
||||
if(payMemberProjectSubitem.getAmountReceivable().compareTo(new BigDecimal("0")) > 0){
|
||||
paySendContactsMessageDTO.setFlag(ProjectCommon.FLAG0 + "," + ProjectCommon.FLAG1);
|
||||
}
|
||||
@@ -220,7 +220,7 @@ public class PayPayMemberProjectSubitemServiceImpl extends ServiceImpl<PayMember
|
||||
// if (!payMemberProjectSubitem1.getPostContactTemporaryId().equals(postContactId)) {
|
||||
// contactsManagementTemporaryService.removeById(postContactId);
|
||||
// }
|
||||
// 变更应收金额,重新校验状态
|
||||
// 变更待确收金额,重新校验状态
|
||||
ProjectStatusVO projectStatusVO = projectDetailService.getStatus(payMemberProjectSubitem.getId(),payMemberProjectSubitem.getAmountReceivable(),payMemberProjectSubitem.getNeedInvoice());
|
||||
if(!Objects.isNull(projectStatusVO)){
|
||||
if(!Objects.isNull(projectStatusVO.getInAccount())){
|
||||
|
||||
+5
-5
@@ -55,12 +55,12 @@ public class PayMemberProjectSubitemExcel {
|
||||
private String postContactId;
|
||||
|
||||
/**
|
||||
* 应收金额
|
||||
* 待确收金额
|
||||
*/
|
||||
@Excel(name = "应收金额", width = 15,orderNum = "4")
|
||||
@ApiModelProperty(value = "应收金额")
|
||||
@NotBlank(message = "应收金额不能为空")
|
||||
@Pattern(regexp = "^[0-9]{1,10}(\\.[0-9]{1,2})?$",message = "应收金额格式错误")
|
||||
@Excel(name = "待确收金额", width = 15,orderNum = "4")
|
||||
@ApiModelProperty(value = "待确收金额")
|
||||
@NotBlank(message = "待确收金额不能为空")
|
||||
@Pattern(regexp = "^[0-9]{1,10}(\\.[0-9]{1,2})?$",message = "待确收金额格式错误")
|
||||
private String amountReceivable;
|
||||
|
||||
|
||||
|
||||
@@ -105,11 +105,11 @@ public class PayProjectExcel implements Serializable {
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty(value = "联系人邮箱")
|
||||
private String email;
|
||||
/**应收金额(元)*/
|
||||
@Excel(name = "应收金额(元)", width = 15)
|
||||
@ApiModelProperty(value = "应收金额(元)")
|
||||
@NotNull(message = "应收金额(元)不能为空!")
|
||||
@DecimalMax(value = "9999999999.99",message = "应收金额(元)格式错误")
|
||||
/**待确收金额(元)*/
|
||||
@Excel(name = "待确收金额(元)", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额(元)")
|
||||
@NotNull(message = "待确收金额(元)不能为空!")
|
||||
@DecimalMax(value = "9999999999.99",message = "待确收金额(元)格式错误")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal receivableAmount;
|
||||
/**实收金额(元)*/
|
||||
|
||||
+2
-2
@@ -751,13 +751,13 @@ public class PayPaymentCheckServiceImpl extends ServiceImpl<PayPaymentCheckMappe
|
||||
paidAmount = new BigDecimal("0.00");
|
||||
}
|
||||
|
||||
// 实收金额 < 应收金额 && 不等于待审核/已拒绝
|
||||
// 实收金额 < 待确收金额 && 不等于待审核/已拒绝
|
||||
if(paidAmount.compareTo(amountReceivable) < 0
|
||||
&& !PaymentStatusEnum.TO_BE_REVIEWED.getCode().equals(paymentStatus)
|
||||
&& !PaymentStatusEnum.REJECTED.getCode().equals(paymentStatus)){
|
||||
paymentStatus = PaymentStatusEnum.TO_BE_UPLOADED.getCode();//待上传
|
||||
}
|
||||
// 应收>0 && 实收金额 == 应收金额
|
||||
// 应收>0 && 实收金额 == 待确收金额
|
||||
if(amountReceivable.compareTo(new BigDecimal("0.00")) > 0
|
||||
&& paidAmount.compareTo(amountReceivable) == 0){
|
||||
paymentStatus = PaymentStatusEnum.COMPLETED.getCode();//已完结
|
||||
|
||||
+5
-5
@@ -90,11 +90,11 @@ public class PayCommonProject implements Serializable {
|
||||
@ApiModelProperty(value = "临时联系人名称")
|
||||
@Excel(name = "企业联系人", width = 15,orderNum = "3")
|
||||
private String contactsTemporaryName;
|
||||
/**应收金额(元)*/
|
||||
@Excel(name = "应收金额(元)", width = 15,orderNum = "4")
|
||||
@ApiModelProperty(value = "应收金额(元)")
|
||||
@NotNull(message = "应收金额(元)不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "应收金额(元)格式错误")
|
||||
/**待确收金额(元)*/
|
||||
@Excel(name = "待确收金额(元)", width = 15,orderNum = "4")
|
||||
@ApiModelProperty(value = "待确收金额(元)")
|
||||
@NotNull(message = "待确收金额(元)不能为空")
|
||||
@DecimalMax(value = "9999999999.99",message = "待确收金额(元)格式错误")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal receivableAmount;
|
||||
/**实收金额(元)*/
|
||||
|
||||
+4
-4
@@ -117,10 +117,10 @@ public class PayWorkingGroupSubItem implements Serializable {
|
||||
@ApiModelProperty(value = "来款方式(1:无,2:合同,3:收费通知)")
|
||||
@NotNull(message = "来款方式不能为空")
|
||||
private java.lang.Integer chargeWay;
|
||||
/**应收金额(元)*/
|
||||
@Excel(name = "应收金额(元)", width = 15)
|
||||
@ApiModelProperty(value = "应收金额(元)")
|
||||
@DecimalMax(value = "9999999999.99",message = "应收金额(元)格式错误")
|
||||
/**待确收金额(元)*/
|
||||
@Excel(name = "待确收金额(元)", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额(元)")
|
||||
@DecimalMax(value = "9999999999.99",message = "待确收金额(元)格式错误")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal receivableAmount;
|
||||
/**实收金额(元)*/
|
||||
|
||||
+2
-2
@@ -149,7 +149,7 @@ public class PayCommonProjectServiceImpl extends ServiceImpl<PayCommonProjectMap
|
||||
paySendContactsMessageDTO.setPhone(payContactsManagement.getPhone());
|
||||
paySendContactsMessageDTO.setUserId(payCommonProject.getPrincipalId());
|
||||
paySendContactsMessageDTO.setFlag(ProjectCommon.FLAG0);
|
||||
// 项目的应收金额>0 发送缴费通知
|
||||
// 项目的待确收金额>0 发送缴费通知
|
||||
if(!Objects.isNull(payCommonProject.getReceivableAmount()) && payCommonProject.getReceivableAmount().compareTo(new BigDecimal("0")) > 0){
|
||||
paySendContactsMessageDTO.setFlag(ProjectCommon.FLAG0 + "," + ProjectCommon.FLAG1);
|
||||
}
|
||||
@@ -223,7 +223,7 @@ public class PayCommonProjectServiceImpl extends ServiceImpl<PayCommonProjectMap
|
||||
}
|
||||
|
||||
setPayCommonProjectEdit(payCommonProject,payCommonProjectOld);
|
||||
// 变更应收金额,重新校验状态
|
||||
// 变更待确收金额,重新校验状态
|
||||
ProjectStatusVO projectStatusVO = projectDetailService.getStatus(payCommonProject.getId(),payCommonProject.getReceivableAmount(),payCommonProject.getNeedInvoice());
|
||||
if(!Objects.isNull(projectStatusVO)){
|
||||
if(!Objects.isNull(projectStatusVO.getInAccount())){
|
||||
|
||||
+1
-1
@@ -346,7 +346,7 @@ public class PayWorkingGroupServiceImpl extends ServiceImpl<PayWorkingGroupMappe
|
||||
paySendContactsMessageDTO.setUserId(payWorkingGroupOld.getPrincipalIdA());
|
||||
paySendContactsMessageDTO.setPhone(payContactsManagement.getPhone());
|
||||
paySendContactsMessageDTO.setFlag(ProjectCommon.FLAG0);
|
||||
// 项目的应收金额>0 发送缴费通知
|
||||
// 项目的待确收金额>0 发送缴费通知
|
||||
if(!Objects.isNull(p.getReceivableAmount()) && p.getReceivableAmount().compareTo(new BigDecimal("0")) > 0){
|
||||
paySendContactsMessageDTO.setFlag(ProjectCommon.FLAG0 + "," + ProjectCommon.FLAG1);
|
||||
}
|
||||
|
||||
+9
-9
@@ -183,7 +183,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
|
||||
if(Objects.equals(payWorkingGroupSubItem.getChargeWay(),PayProjectCommon.CHARGE_WAY2)){
|
||||
if(Objects.isNull(payWorkingGroupSubItem.getReceivableAmount())){
|
||||
throw new JeroBootException("应收金额不能为空");
|
||||
throw new JeroBootException("待确收金额不能为空");
|
||||
}
|
||||
if(StringUtils.isBlank(payWorkingGroupSubItem.getContractNum())){
|
||||
throw new JeroBootException("合同号不能为空");
|
||||
@@ -194,7 +194,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
throw new JeroBootException("收费通知号不能为空");
|
||||
}
|
||||
if(Objects.isNull(payWorkingGroupSubItem.getReceivableAmount())){
|
||||
throw new JeroBootException("应收金额不能为空");
|
||||
throw new JeroBootException("待确收金额不能为空");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -292,7 +292,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
paySendContactsMessageDTO.setListFile(listFile);
|
||||
}
|
||||
paySendContactsMessageDTO.setFlag(ProjectCommon.FLAG0);
|
||||
// 项目的应收金额>0 发送缴费通知
|
||||
// 项目的待确收金额>0 发送缴费通知
|
||||
if(!Objects.isNull(payWorkingGroupSubItem.getReceivableAmount()) && payWorkingGroupSubItem.getReceivableAmount().compareTo(new BigDecimal("0")) > 0){
|
||||
paySendContactsMessageDTO.setFlag(ProjectCommon.FLAG0 + "," + ProjectCommon.FLAG1);
|
||||
}
|
||||
@@ -331,7 +331,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
}
|
||||
if(Objects.equals(payWorkingGroupSubItem.getChargeWay(),PayProjectCommon.CHARGE_WAY2)){
|
||||
if(Objects.isNull(payWorkingGroupSubItem.getReceivableAmount())){
|
||||
throw new JeroBootException("应收金额不能为空");
|
||||
throw new JeroBootException("待确收金额不能为空");
|
||||
}
|
||||
if(StringUtils.isBlank(payWorkingGroupSubItem.getContractNum())){
|
||||
throw new JeroBootException("合同号不能为空");
|
||||
@@ -342,7 +342,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
throw new JeroBootException("收费通知号不能为空");
|
||||
}
|
||||
if(Objects.isNull(payWorkingGroupSubItem.getReceivableAmount())){
|
||||
throw new JeroBootException("应收金额不能为空");
|
||||
throw new JeroBootException("待确收金额不能为空");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -411,7 +411,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
payWorkingGroupSubItemContactsService.saveBatch(listPayWorkingGroupSubItemContactsNew);
|
||||
}
|
||||
payWorkingGroupSubItem.setChargeUse(PayProjectCommon.CHARGE_USE1);
|
||||
// 变更应收金额,重新校验状态
|
||||
// 变更待确收金额,重新校验状态
|
||||
ProjectStatusVO projectStatusVO = projectDetailService.getStatus(workingGroupSubItemId,payWorkingGroupSubItem.getReceivableAmount(),payWorkingGroupSubItem.getNeedInvoice());
|
||||
if(!Objects.isNull(projectStatusVO)){
|
||||
if(!Objects.isNull(projectStatusVO.getInAccount())){
|
||||
@@ -628,7 +628,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
// 校验
|
||||
if (Objects.equals(p.getChargeWay(), PayProjectCommon.CHARGE_WAY2)) {
|
||||
if (Objects.isNull(p.getReceivableAmount())) {
|
||||
msg.append("第").append(count + 3).append("行:应收金额不能为空,请修改。<br/>");
|
||||
msg.append("第").append(count + 3).append("行:待确收金额不能为空,请修改。<br/>");
|
||||
}
|
||||
if (StringUtils.isBlank(p.getContractNum())) {
|
||||
msg.append("第").append(count + 3).append("行:合同号不能为空,请修改。<br/>");
|
||||
@@ -660,7 +660,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
}
|
||||
}
|
||||
if (Objects.isNull(p.getReceivableAmount())) {
|
||||
msg.append("第").append(count + 3).append("行:应收金额不能为空,请修改。<br/>");
|
||||
msg.append("第").append(count + 3).append("行:待确收金额不能为空,请修改。<br/>");
|
||||
}
|
||||
}
|
||||
p.setChargeUse(PayProjectCommon.CHARGE_USE1);
|
||||
@@ -925,7 +925,7 @@ public class PayWorkingGroupSubItemServiceImpl extends ServiceImpl<PayWorkingGro
|
||||
return;
|
||||
}
|
||||
LambdaUpdateWrapper<PayWorkingGroupSubItem> updatePayWorkingGroupSubItem = new LambdaUpdateWrapper<>();
|
||||
// 变更应收金额,重新校验状态
|
||||
// 变更待确收金额,重新校验状态
|
||||
ProjectStatusVO projectStatusVO = projectDetailService.getStatus(p.getId(),input.getReceivableAmount(),p.getNeedInvoice());
|
||||
if(!Objects.isNull(projectStatusVO)){
|
||||
if(!Objects.isNull(projectStatusVO.getInAccount())){
|
||||
|
||||
@@ -20,10 +20,10 @@ public class SetChargeInput implements Serializable {
|
||||
@ApiModelProperty(value = "收费通知唯一标识(收费通知号A:a,收费通知号B:b)")
|
||||
@NotEmpty(message = "收费通知唯一标识不能为空")
|
||||
private java.lang.String charge;
|
||||
/**应收金额(元)*/
|
||||
@ApiModelProperty(value = "应收金额(元)")
|
||||
@DecimalMax(value = "9999999999.99",message = "应收金额(元)格式错误")
|
||||
@NotNull(message = "应收金额(元)不能为空!")
|
||||
/**待确收金额(元)*/
|
||||
@ApiModelProperty(value = "待确收金额(元)")
|
||||
@DecimalMax(value = "9999999999.99",message = "待确收金额(元)格式错误")
|
||||
@NotNull(message = "待确收金额(元)不能为空!")
|
||||
private BigDecimal receivableAmount;
|
||||
/**收费通知号*/
|
||||
@ApiModelProperty(value = "收费通知号")
|
||||
|
||||
+3
-3
@@ -38,10 +38,10 @@ public class PayWorkingGroupSubItemExcel implements Serializable {
|
||||
@ApiModelProperty(value = "来款方式(1:无,2:合同,3:收费通知)")
|
||||
private Integer chargeWay;
|
||||
/**
|
||||
* 应收金额(元)
|
||||
* 待确收金额(元)
|
||||
*/
|
||||
@Excel(name = "应收金额(元)", width = 15)
|
||||
@ApiModelProperty(value = "应收金额(元)")
|
||||
@Excel(name = "待确收金额(元)", width = 15)
|
||||
@ApiModelProperty(value = "待确收金额(元)")
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private BigDecimal receivableAmount;
|
||||
/**
|
||||
|
||||
@@ -22,17 +22,17 @@ public class AmountUtil {
|
||||
/**
|
||||
* 计算到账状态
|
||||
*
|
||||
* @param amountReceivable 应收金额
|
||||
* @param amountReceivable 待确收金额
|
||||
* @param paidAmount 实收金额
|
||||
* @return
|
||||
*/
|
||||
public static int calculate(Integer amountReceivable, Integer paidAmount) {
|
||||
//应收金额大于0时
|
||||
//待确收金额大于0时
|
||||
if (amountReceivable > 0) {
|
||||
//实收金额等于应收金额
|
||||
//实收金额等于待确收金额
|
||||
if (paidAmount.equals(amountReceivable)) {
|
||||
return 2;
|
||||
//实收金额大于0小于应收金额时
|
||||
//实收金额大于0小于待确收金额时
|
||||
} else if (paidAmount > 0 && paidAmount < amountReceivable) {
|
||||
return 1;
|
||||
//实收金额等于0时
|
||||
|
||||
Reference in New Issue
Block a user