|
|
@@ -2320,7 +2320,7 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
jqCommissionRatio = batchModifyVo.getJqSuperviseCostsProportion();
|
|
|
jqFollowRatio = BigDecimalUtil.subtract(jqInletRatio,jqCommissionRatio);
|
|
|
}else if(batchModifyVo.getJqSuperviseCostsProportion() == null && batchModifyVo.getJqOtherCostsProportion() != null){
|
|
|
- jqCommissionRatio = BigDecimalUtil.toZero(insPlyIncome.getJqSuperviseCostsProportion());
|
|
|
+ jqCommissionRatio = BigDecimalUtil.null2Zero(insPlyIncome.getJqSuperviseCostsProportion());
|
|
|
jqFollowRatio = batchModifyVo.getJqOtherCostsProportion();
|
|
|
jqInletRatio = BigDecimalUtil.add(jqCommissionRatio,jqFollowRatio);
|
|
|
}else if(batchModifyVo.getJqSuperviseCostsProportion() != null && batchModifyVo.getJqOtherCostsProportion() != null){
|
|
|
@@ -2329,8 +2329,8 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
jqInletRatio = BigDecimalUtil.add(jqCommissionRatio,jqFollowRatio);
|
|
|
}else if(batchModifyVo.getJqSuperviseCostsProportion() == null && batchModifyVo.getJqOtherCostsProportion() == null){
|
|
|
jqInletRatio = insFeeOrders.getJqInletRatio();
|
|
|
- jqCommissionRatio = BigDecimalUtil.toZero(insPlyIncome.getJqSuperviseCostsProportion());
|
|
|
- jqFollowRatio = BigDecimalUtil.toZero(insPlyIncome.getJqOtherCostsProportion());
|
|
|
+ jqCommissionRatio = BigDecimalUtil.null2Zero(insPlyIncome.getJqSuperviseCostsProportion());
|
|
|
+ jqFollowRatio = BigDecimalUtil.null2Zero(insPlyIncome.getJqOtherCostsProportion());
|
|
|
}
|
|
|
vo.setJqInletRatio(jqInletRatio);
|
|
|
vo.setJqCommissionRatio(jqCommissionRatio);
|
|
|
@@ -2345,7 +2345,7 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
syCommissionRatio = batchModifyVo.getSySuperviseCostsProportion();
|
|
|
syFollowRatio = BigDecimalUtil.subtract(syInletRatio,syCommissionRatio);
|
|
|
}else if(batchModifyVo.getSySuperviseCostsProportion() == null && null != batchModifyVo.getSyOtherCostsProportion()){
|
|
|
- syCommissionRatio = BigDecimalUtil.toZero(insPlyIncome.getSySuperviseCostsProportion());
|
|
|
+ syCommissionRatio = BigDecimalUtil.null2Zero(insPlyIncome.getSySuperviseCostsProportion());
|
|
|
syFollowRatio = batchModifyVo.getSyOtherCostsProportion();
|
|
|
syInletRatio = BigDecimalUtil.add(syCommissionRatio,syFollowRatio);
|
|
|
}else if(batchModifyVo.getSySuperviseCostsProportion() != null && batchModifyVo.getSyOtherCostsProportion() != null){
|
|
|
@@ -2354,8 +2354,8 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
syInletRatio = BigDecimalUtil.add(syCommissionRatio,syFollowRatio);
|
|
|
}else if(batchModifyVo.getSySuperviseCostsProportion() == null && batchModifyVo.getSyOtherCostsProportion() == null){
|
|
|
syInletRatio = insFeeOrders.getSyInletRatio();
|
|
|
- syCommissionRatio = BigDecimalUtil.toZero(insPlyIncome.getSySuperviseCostsProportion());
|
|
|
- syFollowRatio = BigDecimalUtil.toZero(insPlyIncome.getSyOtherCostsProportion());
|
|
|
+ syCommissionRatio = BigDecimalUtil.null2Zero(insPlyIncome.getSySuperviseCostsProportion());
|
|
|
+ syFollowRatio = BigDecimalUtil.null2Zero(insPlyIncome.getSyOtherCostsProportion());
|
|
|
}
|
|
|
vo.setSyInletRatio(syInletRatio);
|
|
|
vo.setSyCommissionRatio(syCommissionRatio);
|
|
|
@@ -2370,7 +2370,7 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
jyCommissionRatio = batchModifyVo.getJySuperviseCostsProportion();
|
|
|
jyFollowRatio = BigDecimalUtil.subtract(jyInletRatio,jyCommissionRatio);
|
|
|
}else if(batchModifyVo.getJySuperviseCostsProportion() == null && batchModifyVo.getJyOtherCostsProportion() != null){
|
|
|
- jyCommissionRatio = BigDecimalUtil.toZero(insPlyIncome.getJySuperviseCostsProportion());
|
|
|
+ jyCommissionRatio = BigDecimalUtil.null2Zero(insPlyIncome.getJySuperviseCostsProportion());
|
|
|
jyFollowRatio = batchModifyVo.getJyOtherCostsProportion();
|
|
|
jyInletRatio = BigDecimalUtil.add(jyCommissionRatio,jyFollowRatio);
|
|
|
}else if(batchModifyVo.getJySuperviseCostsProportion() != null && batchModifyVo.getJyOtherCostsProportion() != null){
|
|
|
@@ -2379,8 +2379,8 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
jyInletRatio = BigDecimalUtil.add(jyCommissionRatio,jyFollowRatio);
|
|
|
}else if(batchModifyVo.getJySuperviseCostsProportion() == null && batchModifyVo.getJyOtherCostsProportion() == null){
|
|
|
jyInletRatio = insFeeOrders.getJyInletRatio();
|
|
|
- jyCommissionRatio = BigDecimalUtil.toZero(insPlyIncome.getJySuperviseCostsProportion());
|
|
|
- jyFollowRatio = BigDecimalUtil.toZero(insPlyIncome.getJyOtherCostsProportion());
|
|
|
+ jyCommissionRatio = BigDecimalUtil.null2Zero(insPlyIncome.getJySuperviseCostsProportion());
|
|
|
+ jyFollowRatio = BigDecimalUtil.null2Zero(insPlyIncome.getJyOtherCostsProportion());
|
|
|
}
|
|
|
vo.setJyInletRatio(jyInletRatio);
|
|
|
vo.setJyCommissionRatio(jyCommissionRatio);
|
|
|
@@ -2478,6 +2478,9 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
BigDecimal taxRate = taxRateMap.getOrDefault(income.getOrderNo(), BigDecimal.ONE);
|
|
|
InsPlyIncome updateIncome = new InsPlyIncome();
|
|
|
updateIncome.setId(income.getId());
|
|
|
+ updateIncome.setJqPremium(income.getJqPremium());
|
|
|
+ updateIncome.setSyPremium(income.getSyPremium());
|
|
|
+ updateIncome.setJyPremium(income.getJyPremium());
|
|
|
// 因为 实体对象的settlementStatus设置了初始默认值0, 为了避免已经结算的数据被调整未未结算, 这里将settlementStatus设置为null 2026-6-24 14:33:47
|
|
|
updateIncome.setSettlementStatus(null);
|
|
|
// 根据income的order_no查询inss_fee_order
|
|
|
@@ -2555,9 +2558,9 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
private void calPremium(InsPlyIncome updateIncome, PtlAgreementCostRatioVo ratioVo, BigDecimal taxRate) {
|
|
|
log.info("根据入口比例等比例值计算对应的金额。 ptlAgreementCostRatioVo=[{}], updateIncome=[{}]", JSONUtil.toJsonStr(ratioVo), JSONUtil.toJsonStr(updateIncome));
|
|
|
|
|
|
- BigDecimal jqPremium = BigDecimalUtil.toZero(updateIncome.getJqPremium());
|
|
|
- BigDecimal syPremium = BigDecimalUtil.toZero(updateIncome.getSyPremium()) ;
|
|
|
- BigDecimal jyPremium = BigDecimalUtil.toZero(updateIncome.getJyPremium());
|
|
|
+ BigDecimal jqPremium = BigDecimalUtil.null2Zero(updateIncome.getJqPremium());
|
|
|
+ BigDecimal syPremium = BigDecimalUtil.null2Zero(updateIncome.getSyPremium()) ;
|
|
|
+ BigDecimal jyPremium = BigDecimalUtil.null2Zero(updateIncome.getJyPremium());
|
|
|
|
|
|
|
|
|
BigDecimal jqInletPremium = BigDecimalUtil.divide(BigDecimalUtil.multiply(jqPremium,ratioVo.getJqInletRatio()), taxRate);
|
|
|
@@ -2725,22 +2728,22 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
if (insFeeOrders != null) {
|
|
|
switch (type) {
|
|
|
case "jqFollow":
|
|
|
- followPremium = BigDecimalUtil.toZero(insFeeOrders.getJqFollowPremium());
|
|
|
+ followPremium = BigDecimalUtil.null2Zero(insFeeOrders.getJqFollowPremium());
|
|
|
break;
|
|
|
case "syFollow":
|
|
|
- followPremium = BigDecimalUtil.toZero(insFeeOrders.getSyFollowPremium());
|
|
|
+ followPremium = BigDecimalUtil.null2Zero(insFeeOrders.getSyFollowPremium());
|
|
|
break;
|
|
|
case "jqCommission":
|
|
|
- followPremium = BigDecimalUtil.toZero(insFeeOrders.getJqCommissionPremium());
|
|
|
+ followPremium = BigDecimalUtil.null2Zero(insFeeOrders.getJqCommissionPremium());
|
|
|
break;
|
|
|
case "syCommission":
|
|
|
- followPremium = BigDecimalUtil.toZero(insFeeOrders.getSyCommissionPremium());
|
|
|
+ followPremium = BigDecimalUtil.null2Zero(insFeeOrders.getSyCommissionPremium());
|
|
|
break;
|
|
|
case "jyCommission":
|
|
|
- followPremium = BigDecimalUtil.toZero(insFeeOrders.getJyCommissionPremium());
|
|
|
+ followPremium = BigDecimalUtil.null2Zero(insFeeOrders.getJyCommissionPremium());
|
|
|
break;
|
|
|
case "jyFollow":
|
|
|
- followPremium = BigDecimalUtil.toZero(insFeeOrders.getJyFollowPremium());
|
|
|
+ followPremium = BigDecimalUtil.null2Zero(insFeeOrders.getJyFollowPremium());
|
|
|
break;
|
|
|
}
|
|
|
}
|