Browse Source

修改币种与数量未除100的问题

huangqizheng/feature-20251119150446-退款合并后
huangqizhen 1 week ago
parent
commit
641c32fbfb
  1. 8
      src/main/java/com/example/demo/serviceImpl/cash/CashRefundServiceImpl.java

8
src/main/java/com/example/demo/serviceImpl/cash/CashRefundServiceImpl.java

@ -140,9 +140,13 @@ public class CashRefundServiceImpl implements RefundService {
item.setFree(free);
item.setActivity(cashCollection.getActivity());
item.setPaymentCurrency(cashCollection.getPaymentCurrency());
item.setPaymentAmount(cashCollection.getPaymentAmount().divide(new BigDecimal(100), 2, RoundingMode.HALF_UP));
if(cashCollection.getPaymentCurrency() != null){
item.setPaymentAmount(cashCollection.getPaymentAmount().divide(new BigDecimal(100), 2, RoundingMode.HALF_UP));}
else item.setPaymentAmount(cashCollection.getPaymentAmount());
item.setReceivedCurrency(cashCollection.getReceivedCurrency());
item.setReceivedAmount(cashCollection.getReceivedAmount().divide(new BigDecimal(100), 2, RoundingMode.HALF_UP));
if (cashCollection.getReceivedCurrency() != null){
item.setReceivedAmount(cashCollection.getReceivedAmount().divide(new BigDecimal(100), 2, RoundingMode.HALF_UP));}
else item.setReceivedAmount(cashCollection.getReceivedAmount());
item.setPayType(cashCollection.getPayType());
item.setPayTime(cashCollection.getPayTime());
item.setPayBankCode(cashCollection.getBankCode());

Loading…
Cancel
Save