Ver código fonte

12.31后手续费单独计算

周箭河 4 anos atrás
pai
commit
374bcda15f

+ 4 - 1
mec-web/src/main/java/com/ym/mec/web/controller/ExportController.java

@@ -2164,7 +2164,10 @@ public class ExportController extends BaseController {
             if (row.getBalancePaymentAmount() == null) {
                 row.setBalancePaymentAmount(BigDecimal.ZERO);
             }
-            BigDecimal transferFee = (row.getActualAmount().multiply(new BigDecimal("0.28")).divide(new BigDecimal(100))).setScale(2, BigDecimal.ROUND_HALF_UP);
+            BigDecimal transferFee = row.getActualAmount().multiply(new BigDecimal("0.28")).divide(new BigDecimal(100),2,BigDecimal.ROUND_HALF_UP);
+            if (row.getCreateTime().after(Objects.requireNonNull(DateUtil.stringToDate("2020-12-31 23:59:59", "yyyy-MM-dd HH:mm:ss")))) {
+                transferFee = row.getRouteAmount().multiply(new BigDecimal("0.28")).divide(new BigDecimal(100),2,BigDecimal.ROUND_HALF_UP);
+            }
             row.setTransferFee(transferFee);
             BigDecimal musicalFee = BigDecimal.ZERO;
             BigDecimal teachingFee = BigDecimal.ZERO;