fix(tenpayv3): 修复查询分账结果接口的调用时参数缺失问题

This commit is contained in:
Fu Diwei 2021-09-23 17:04:19 +08:00
parent fb194a6383
commit 5a11338e08
3 changed files with 8 additions and 6 deletions

View File

@ -35,7 +35,7 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3
}
/// <summary>
/// <para>异步调用 [GET] /profitsharing/orders 接口。</para>
/// <para>异步调用 [GET] /profitsharing/orders/{out_order_no} 接口。</para>
/// <para>REF: https://pay.weixin.qq.com/wiki/doc/apiv3/apis/chapter8_1_2.shtml </para>
/// <para>REF: https://pay.weixin.qq.com/wiki/doc/apiv3_partner/apis/chapter8_1_2.shtml </para>
/// </summary>
@ -49,9 +49,11 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3
if (request is null) throw new ArgumentNullException(nameof(request));
IFlurlRequest flurlReq = client
.CreateRequest(request, HttpMethod.Get, "profitsharing", "orders")
.SetQueryParam("transaction_id", request.TransactionId)
.SetQueryParam("out_order_no", request.OutOrderNumber);
.CreateRequest(request, HttpMethod.Get, "profitsharing", "orders", request.OutOrderNumber)
.SetQueryParam("transaction_id", request.TransactionId);
if (!string.IsNullOrEmpty(request.SubMerchantId))
flurlReq.SetQueryParam("sub_mchid", request.SubMerchantId);
return await client.SendRequestWithJsonAsync<Models.GetProfitSharingOrderByOutOrderNumberResponse>(flurlReq, cancellationToken: cancellationToken);
}

View File

@ -4,7 +4,7 @@ using System.Collections.Generic;
namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.Models
{
/// <summary>
/// <para>表示 [GET] /profitsharing/orders 接口的请求。</para>
/// <para>表示 [GET] /profitsharing/orders/{out_order_no} 接口的请求。</para>
/// </summary>
public class GetProfitSharingOrderByOutOrderNumberRequest : WechatTenpayRequest
{

View File

@ -4,7 +4,7 @@ using System.Collections.Generic;
namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.Models
{
/// <summary>
/// <para>表示 [GET] /profitsharing/orders 接口的响应。</para>
/// <para>表示 [GET] /profitsharing/orders/{out_order_no} 接口的响应。</para>
/// </summary>
public class GetProfitSharingOrderByOutOrderNumberResponse : WechatTenpayResponse
{