记得上下班打卡 | git大法好,push需谨慎

Commit 1d1bcbb7 authored by zhoujianping's avatar zhoujianping

1.支付宝小程序退款接口增加退款日志

parent a48cc5bc
......@@ -543,6 +543,7 @@ public class DragonOrderRefundsServiceImpl implements IDragonOrderRefundsService
//支付宝退款接口
public DragonRefundChannelDto aliPayRefund(String orderRefundId, String refundCode, String code, String reason, BigDecimal price, String paymentId, String paymentType, LocalDateTime nowTime) {
log.info("支付宝退款入参orderRefundId={},refundCode={},code={},reason={},price={},paymentId={},paymentType={}",orderRefundId,refundCode,code,reason,price,paymentId,paymentType);
String refundStatus;
DragonRefundChannelDto channelDto = new DragonRefundChannelDto();
RefundContentDto contentDto = new RefundContentDto();
......@@ -563,7 +564,7 @@ public class DragonOrderRefundsServiceImpl implements IDragonOrderRefundsService
httpClient=PayAlipayUtils.getInstance().getHttpClient();
}
AlipayTradeRefundResponse response = httpClient.execute(request);
log.info("支付宝退款AlipayTradeRefundResponse={}",response);
log.info("支付宝退款AlipayTradeRefundResponse={}",response.getBody());
if (response.getFundChange() == null || response.getFundChange().equals("N")) {
try {
refundStatus = DragonConstant.RefundStatusEnum.STATUS_ERROR.getCode();
......@@ -605,12 +606,14 @@ public class DragonOrderRefundsServiceImpl implements IDragonOrderRefundsService
);
try {
String refundAt = "";
log.info("支付宝退款FundChange={}",response.getFundChange());
if (response.getFundChange().equals("Y")) {
refundStatus = DragonConstant.RefundStatusEnum.STATUS_REFUNDED.getCode();
refundAt = DateUtil.format(response.getGmtRefundPay(), DateUtil.Formatter.yyyyMMddHHmmss);
} else {
refundStatus = DragonConstant.RefundStatusEnum.STATUS_REFUNDING.getCode();
}
log.info("支付宝退款成功code={},refundStatus={}",code,refundStatus);
mqHandleUtil.sendMySqlRedis(
SqlMapping.get("dragon_order_refund_success.update"),
new Object[]{nowTime, refundAt, refundStatus, code},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment