|
|
@@ -484,6 +484,12 @@ public class InvReceivableServiceImpl implements InvReceivableService {
|
|
|
invSource.setSyPremium(invSource.getSyPremiumTax().divide(tax,2, RoundingMode.HALF_UP));
|
|
|
//处理非车不含税
|
|
|
invSource.setNonCarPremium(invSource.getNonCarPremiumTax().divide(tax,2, RoundingMode.HALF_UP));
|
|
|
+
|
|
|
+ //处理非跟单比例
|
|
|
+ invSource.setJqNonCopyingRatio(invSource.getJqReceivableRatio().subtract(invSource.getJqPremiumRatio()));
|
|
|
+ invSource.setSyNonCopyingRatio(invSource.getSyReceivableRatio().subtract(invSource.getSyPremiumRatio()));
|
|
|
+ invSource.setNonCarNonCopyingRatio(invSource.getNonCarReceivableRatio().subtract(invSource.getNonCarPremiumRatio()));
|
|
|
+
|
|
|
//处理手续费金额
|
|
|
invSource.setPremium(
|
|
|
invSource.getJqPremium().multiply(invSource.getJqPremiumRatio())
|
|
|
@@ -604,9 +610,10 @@ public class InvReceivableServiceImpl implements InvReceivableService {
|
|
|
@Override
|
|
|
public Boolean updateSettlement(InvSettlementSource invSettlementSource) {
|
|
|
//处理结算金额
|
|
|
- invSettlementSource.setSettlementAmount(invSettlementSource.getJqPremiumTax().multiply(invSettlementSource.getCompulsoryExportRatio()
|
|
|
+ BigDecimal settlementAmount = invSettlementSource.getJqPremiumTax().multiply(invSettlementSource.getCompulsoryExportRatio())
|
|
|
.add(invSettlementSource.getSyPremiumTax().multiply(invSettlementSource.getCommercialExportRatio()))
|
|
|
- .add(invSettlementSource.getNonCarPremiumTax().multiply(invSettlementSource.getNonVehicleExportRatio()))));
|
|
|
+ .add(invSettlementSource.getNonCarPremiumTax().multiply(invSettlementSource.getNonVehicleExportRatio()));
|
|
|
+ invSettlementSource.setSettlementAmount(settlementAmount);
|
|
|
return invSettlementSourceMapper.updateById(invSettlementSource) > 0 ? true : false;
|
|
|
}
|
|
|
|