fix: 微信支付,接口测试问题修复。

This commit is contained in:
tianyongbao
2026-01-19 14:29:42 +08:00
parent 3fc42ac5b9
commit 4e5c94b427
3 changed files with 31 additions and 0 deletions

View File

@@ -244,6 +244,12 @@ public class WeixinController extends BaseController {
return R.fail("创建微信预支付订单失败");
}
// 7.1 更新订单的prepayId
boolean updated = payOrderBusinessService.updatePrepayId(orderId, prepayId);
if (!updated) {
log.warn("更新订单prepayId失败: orderId={}, prepayId={}", orderId, prepayId);
}
// 8. 生成JSAPI支付参数
String appId = wxMaProperties != null && wxMaProperties.getAppId() != null ?
wxMaProperties.getAppId() : "";