From 543848d59a74eb0640718101ab90df44d5089673 Mon Sep 17 00:00:00 2001 From: hurui <177768073@qq.com> Date: Thu, 15 Jun 2023 12:03:26 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/BsTradeOrderServiceImpl.java | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/service/src/main/java/com/hfkj/service/impl/BsTradeOrderServiceImpl.java b/service/src/main/java/com/hfkj/service/impl/BsTradeOrderServiceImpl.java index b161153..17676b9 100644 --- a/service/src/main/java/com/hfkj/service/impl/BsTradeOrderServiceImpl.java +++ b/service/src/main/java/com/hfkj/service/impl/BsTradeOrderServiceImpl.java @@ -57,7 +57,7 @@ public class BsTradeOrderServiceImpl implements BsTradeOrderService { @Resource private UserDiscountService userDiscountService; @Resource - private BsMerPlatformNoRateService merPlatformNoRateService; + private BsMerRateService merRateService; @Override public void editOrder(BsTradeOrder tradeOrder) { @@ -222,6 +222,19 @@ public class BsTradeOrderServiceImpl implements BsTradeOrderService { tradeOrder.setStatus(TradeOrderStatusEnum.status3.getNumber()); tradeOrder.setPayTime(new Date()); + // WECHAT ALIPAY + if (tradeOrder.getPayMode().equals(TradeOrderPayModeEnum.WECHAT.getCode())) { + BsMerRate rate = merRateService.getDetail(tradeOrder.getMerId(), 302); + if (rate != null) { + tradeOrder.setFeeRate(rate.getRatePct()); + } + } else if (tradeOrder.getPayMode().equals(TradeOrderPayModeEnum.ALIPAY.getCode())) { + BsMerRate rate = merRateService.getDetail(tradeOrder.getMerId(),303); + if (rate != null) { + tradeOrder.setFeeRate(rate.getRatePct()); + } + } + if (StringUtils.isNotBlank(MapUtils.getString(other, "log_no"))) { tradeOrder.setPlatformLogNo(MapUtils.getString(other, "log_no")); }