فهرست منبع

Merge remote-tracking branch 'origin/dev_jzg_lipf_v20260622' into dev_jzg_lipf_v20260622

jiakai 3 ماه پیش
والد
کامیت
0b83224525

+ 4 - 2
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/service/impl/InsFeeOrdersServiceImpl.java

@@ -16,6 +16,7 @@ import com.jzg.commons.entity.po.PtlAgreement;
 import com.jzg.commons.entity.vo.PtlAgreementCostRatioVo;
 import com.jzg.commons.exception.SystemException;
 import com.jzg.commons.util.AssertionUtils;
+import com.jzg.commons.util.BigDecimalUtil;
 import com.jzg.commons.util.StringUtils;
 import com.jzg.quotation.commons.client.OrgClient;
 import com.jzg.quotation.summary.mapper.InsFeeOrdersMapper;
@@ -180,8 +181,9 @@ public class InsFeeOrdersServiceImpl extends ServiceImpl<InsFeeOrdersMapper, Ins
         // 出口直接乘
         BigDecimal export = premium.multiply(exportRatio).setScale(scale, RoundingMode.HALF_EVEN);
         BigDecimal exportKeepPoint = premium.multiply(exportKeepPointRatio).setScale(scale, RoundingMode.HALF_EVEN);
-        // 留点比例直接乘, modify by lipf ,留点比例在infFeeOrder中计算得到。这里直接使用 2026年6月16日17:32:09
-        BigDecimal keepPoint = premium.multiply(keepPointRatio).setScale(scale, RoundingMode.HALF_EVEN);
+        // 留点比例直接乘, modify by lipf ,留点比例在infFeeOrder中计算得到。这里直接使用 2026年6月16日17:32:09, 为了保持金额一致,留点比例不适用百分比乘积,而是使用金额相减
+        // BigDecimal keepPoint = premium.multiply(keepPointRatio).setScale(scale, RoundingMode.HALF_EVEN);
+        BigDecimal keepPoint = BigDecimalUtil.subtract(BigDecimalUtil.add(commission,addThrow),export);
 
         // 赋值到实体(自动匹配 jq / sy / jy)
         if ("jq".equals(type)) {

+ 4 - 4
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/service/impl/InsOrdersServiceImpl.java

@@ -1357,10 +1357,10 @@ public class InsOrdersServiceImpl extends ServiceImpl<InsOrdersMapper, InsOrders
 //            PtlAgreement ptlAgreement = orgClient.getByAgreementId(insOrdersVo.getInsOrders().getAgreementId());
 //            resultVo.setCostRatio(new PtlAgreementCostRatioVo(ptlAgreementCostTypeList, ptlAgreement));
             resultVo.setCostRatio(new PtlAgreementCostRatioVo(insFeeOrders));
-            // add by lipf, 手动计算留点比例的费用 2026年6月11日11:31:39
-            insFeeOrders.setJqKeepPointPremium(BigDecimalUtil.divide( BigDecimalUtil.multiply(insFeeOrders.getJqPremium(),resultVo.getCostRatio().getJqKeepPointRatio()),new BigDecimal(100)));
-            insFeeOrders.setSyKeepPointPremium(BigDecimalUtil.divide(BigDecimalUtil.multiply(insFeeOrders.getSyPremium(),resultVo.getCostRatio().getSyKeepPointRatio()),new BigDecimal(100)));
-            insFeeOrders.setJyKeepPointPremium(BigDecimalUtil.divide(BigDecimalUtil.multiply(insFeeOrders.getJyPremium(),resultVo.getCostRatio().getJyKeepPointRatio()),new BigDecimal(100)));
+            // add by lipf, 手动计算留点比例的费用 2026年6月11日11:31:39. modify by lipf, 留点比例直接从ins_fee_orders中获取 2026年6月22日17:32:46
+//            insFeeOrders.setJqKeepPointPremium(BigDecimalUtil.divide( BigDecimalUtil.multiply(insFeeOrders.getJqPremium(),resultVo.getCostRatio().getJqKeepPointRatio()),new BigDecimal(100)));
+//            insFeeOrders.setSyKeepPointPremium(BigDecimalUtil.divide(BigDecimalUtil.multiply(insFeeOrders.getSyPremium(),resultVo.getCostRatio().getSyKeepPointRatio()),new BigDecimal(100)));
+//            insFeeOrders.setJyKeepPointPremium(BigDecimalUtil.divide(BigDecimalUtil.multiply(insFeeOrders.getJyPremium(),resultVo.getCostRatio().getJyKeepPointRatio()),new BigDecimal(100)));
             resultVo.setInsFeeOrders(new InsFeeOrdersVo(insFeeOrders));
         }
         //权益信息