退款更新问题

This commit is contained in:
2026-01-17 14:18:27 +08:00
parent 6b3fb08036
commit 5da3b447c7
2 changed files with 7 additions and 7 deletions

View File

@@ -2,6 +2,7 @@ package com.czg.service.order.service.impl;
import cn.hutool.core.collection.CollUtil; import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.convert.Convert; import cn.hutool.core.convert.Convert;
import cn.hutool.core.date.LocalDateTimeUtil;
import cn.hutool.core.util.IdUtil; import cn.hutool.core.util.IdUtil;
import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.StrUtil;
import cn.hutool.crypto.SecureUtil; import cn.hutool.crypto.SecureUtil;
@@ -522,12 +523,11 @@ public class OrderPayServiceImpl implements OrderPayService {
} }
throw new CzgException(refund.getMsg()); throw new CzgException(refund.getMsg());
} else { } else {
paymentService.updateChain() OrderPayment upPayment = new OrderPayment();
.eq(OrderPayment::getId, refundId) upPayment.setPayTime(LocalDateTimeUtil.parse(refund.getData().getRefundTime()));
.set(OrderPayment::getPayTime, refund.getData().getRefundTime()) upPayment.setTradeNumber(refund.getData().getThirdRefundNo());
.set(OrderPayment::getTradeNumber, refund.getData().getThirdRefundNo()) upPayment.setRespJson(refund.getData().getOriginalData());
.set(OrderPayment::getRespJson, refund.getData().getOriginalData()) paymentService.update(upPayment, new QueryWrapper().eq(OrderPayment::getId, refundId));
.update();
} }
} }

View File

@@ -203,7 +203,7 @@ public class PayServiceImpl implements PayService {
return sysParamsService.getSysParamValue(ParamCodeCst.System.POLY_DOMAIN); return sysParamsService.getSysParamValue(ParamCodeCst.System.POLY_DOMAIN);
} }
private String getNotifyUrl(String channel) { private String getNotifyUrl(String channel) {
String notifyUrl = ""; String notifyUrl = "";
if (channel.equals(PayChannelCst.NATIVE)) { if (channel.equals(PayChannelCst.NATIVE)) {
notifyUrl = sysParamsService.getSysParamValue(ParamCodeCst.System.NATIVE_PAY_NOTIFY_URL); notifyUrl = sysParamsService.getSysParamValue(ParamCodeCst.System.NATIVE_PAY_NOTIFY_URL);