From 21f4a97f7eacf344e89094b668cb306c40b1e608 Mon Sep 17 00:00:00 2001 From: xiong Date: Mon, 3 Aug 2026 17:58:48 +0800 Subject: [PATCH] =?UTF-8?q?feat=EF=BC=9A=E5=8D=87=E7=BA=A7=E9=83=A8?= =?UTF-8?q?=E5=88=86=E4=BE=9D=E8=B5=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Directory.Packages.props | 18 +++++++++--------- .../Commerce/WechatPayProvider.cs | 9 +++++++-- 2 files changed, 16 insertions(+), 11 deletions(-) diff --git a/Directory.Packages.props b/Directory.Packages.props index 7603f22..89162b3 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -33,7 +33,7 @@ - + @@ -42,23 +42,23 @@ - - - - - + + + + + - + - + runtime; build; native; contentfiles; analyzers; buildtransitive all - + \ No newline at end of file diff --git a/Tiku.Infrastructure/Commerce/WechatPayProvider.cs b/Tiku.Infrastructure/Commerce/WechatPayProvider.cs index c7a16d8..49d58c8 100644 --- a/Tiku.Infrastructure/Commerce/WechatPayProvider.cs +++ b/Tiku.Infrastructure/Commerce/WechatPayProvider.cs @@ -1,6 +1,7 @@ using System.Text.Json; using Senparc.Weixin; using Senparc.Weixin.Entities; +using Senparc.Weixin.TenPayV3; using Senparc.Weixin.TenPayV3.Apis; using Senparc.Weixin.TenPayV3.Apis.BasePay; using Senparc.Weixin.TenPayV3.Helpers; @@ -111,7 +112,11 @@ internal sealed class WechatPayProvider : IPaymentProvider var clientPayload = string.IsNullOrWhiteSpace(prepayId) ? JsonSerializer.SerializeToElement(new { h5Url }) - : JsonSerializer.SerializeToElement(TenPaySignHelper.GetJsApiUiPackage(appId, prepayId, tenPaySettings)); + : JsonSerializer.SerializeToElement( + TenPaySignHelper.GetJsApiUiPackage( + prepayId, + new TenPayV3Info(tenPaySettings), + JsApiAppType.WxOpen)); var providerPayload = JsonSerializer.SerializeToElement(new { PrepayId = prepayId, @@ -250,4 +255,4 @@ internal sealed class WechatPayProvider : IPaymentProvider public string TenPayV3_WxOpenTenpayNotify { get; set; } = string.Empty; public CertType? EncryptionType { get; set; } } -} \ No newline at end of file +}