This commit is contained in:
Mrx
2026-01-26 15:17:04 +08:00
parent 53a97aa04f
commit 38b275d019
24 changed files with 860 additions and 52 deletions

View File

@@ -90,6 +90,11 @@ func (l *WechatPayCallbackLogic) handleQueryOrderPayment(w http.ResponseWriter,
logx.Errorf("微信支付回调,更新订单失败%+v", updateErr)
return nil
}
// 更新查询用户记录表的 platform_order_id
if rec, findErr := l.svcCtx.QueryUserRecordModel.FindOneByQueryNo(l.ctx, *notification.OutTradeNo); findErr == nil {
rec.PlatformOrderId = lzUtils.StringToNullString(*notification.TransactionId)
_, _ = l.svcCtx.QueryUserRecordModel.Update(l.ctx, nil, rec)
}
if order.Status == "paid" {
if asyncErr := l.svcCtx.AsynqService.SendQueryTask(order.Id); asyncErr != nil {