From dcff7fc4a55201373419c3d2e031a4cdc1612500 Mon Sep 17 00:00:00 2001 From: khy <2908249413@qq.com> Date: Thu, 24 Oct 2024 18:57:03 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BE=AE=E4=BF=A1=E6=94=AF=E4=BB=98=EF=BC=88?= =?UTF-8?q?=E6=97=A5=E5=BF=97=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../trade/service/order/TradeOrderUpdateServiceImpl.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/service/order/TradeOrderUpdateServiceImpl.java b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/service/order/TradeOrderUpdateServiceImpl.java index 86b4ec0..65806ac 100644 --- a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/service/order/TradeOrderUpdateServiceImpl.java +++ b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/service/order/TradeOrderUpdateServiceImpl.java @@ -334,11 +334,12 @@ public class TradeOrderUpdateServiceImpl implements TradeOrderUpdateService { KeyValue orderResult = validateOrderPayable(id, payOrderId); TradeOrderDO order = orderResult.getKey(); PayOrderRespDTO payOrder = orderResult.getValue(); - + System.out.println("交易订单成功id:"+id+"和payOrderId:"+payOrderId); //会员用户信息,支付状态修改 TradeMemberUserDO tradeMemberUserDO = tradeMemberUserService.getUser(getLoginUserId()); TradePaidMemberUserDO tradePaidMemberUserDO = tradePaidMemberUserService.getByIdAndPayOrderId(id,payOrderId); if(tradePaidMemberUserDO != null && tradeMemberUserDO != null){ + System.out.println("进入会员支付修改操作paid:"+tradePaidMemberUserDO+"和member:"+tradeMemberUserDO); tradePaidMemberUserDO.setPayTime(LocalDateTime.now()); tradePaidMemberUserDO.setPaid(true); //过期时间 @@ -350,10 +351,12 @@ public class TradeOrderUpdateServiceImpl implements TradeOrderUpdateService { tradePaidMemberUserDO.setPayType(payType); //更新会员订单 tradePaidMemberUserService.update(tradePaidMemberUserDO); + System.out.println("成功更新会员订单paid:"+tradePaidMemberUserDO); //更新用户会员状态 tradeMemberUserService.updateActivate(tradePaidMemberUserDO.getPayMemberType()); + System.out.println("成功更新用户的会员状态member:"+tradeMemberUserDO); } - + System.out.println("会员修改操作结束!!!"); // 2. 更新 TradeOrderDO 状态为已支付,等待发货 int updateCount = tradeOrderMapper.updateByIdAndStatus(id, order.getStatus(), new TradeOrderDO().setStatus(TradeOrderStatusEnum.UNDELIVERED.getStatus()).setPayStatus(true)