| | |
| | | refundCardEquity.setOccupyRefundTotal(cardEquityRealRefund.getOccupyEqRefundTotal()); |
| | | refundCardEquity.setOccupyRefundIntegral(cardEquityRealRefund.getOccupyEqRefundIntegral()); |
| | | |
| | | logger.info("卡项OCC退款OCC抵扣积分{},OCC总积分{}",refundCard.getOccupyRefundIntegralDeduction(),refundCard.getOccupyRefundIntegral()); |
| | | // 卡项OCC抵扣积分占比OCC总积分 |
| | | proportion = refundCard.getOccupyRefundIntegralDeduction().divide(refundCard.getOccupyRefundIntegral(),20,RoundingMode.HALF_UP); |
| | | logger.info("卡项OCC退款OCC抵扣积分{},OCC总积分{},占比:{}",refundCard.getOccupyRefundIntegralDeduction() |
| | | ,refundCard.getOccupyRefundIntegral(),proportion); |
| | | if (refundCard.getOccupyRefundIntegral() != null && refundCard.getOccupyRefundIntegral().compareTo(BigDecimal.ZERO) != 0){ |
| | | proportion = refundCard.getOccupyRefundIntegralDeduction().divide(refundCard.getOccupyRefundIntegral(),20,RoundingMode.HALF_UP); |
| | | }else { |
| | | proportion = BigDecimal.ZERO; |
| | | } |
| | | logger.info("卡项OCC退款OCC抵扣积分占比OCC总积分:{}",proportion); |
| | | |
| | | refundCardEquity.setOccupyRefundIntegralDeduction(cardEquityRealRefund.getOccupyRefundIntegral().multiply(proportion)); |
| | | refundCardEquity.setOccupyRefundIntegralCash(cardEquityRealRefund.getOccupyIntegralDeduction().multiply(refundCard.getCashRate())); |