26 lines
846 B
C#
26 lines
846 B
C#
using System.Threading.Tasks;
|
|
using Hncore.Infrastructure.Serializer;
|
|
using Hncore.Infrastructure.WebApi;
|
|
using Hncore.Payment.Response;
|
|
using PaymentCenterClient;
|
|
|
|
namespace Hncore.Payment.ClientExtension
|
|
{
|
|
public static class QueryOrderExtension
|
|
{
|
|
/// <summary>
|
|
/// 订单查询
|
|
/// </summary>
|
|
/// <param name="client"></param>
|
|
/// <param name="orderNo"></param>
|
|
/// <returns></returns>
|
|
public static async Task<ApiResult<QueryOrderResponse>> QueryOrder(this PaymentCenterHttpClient client,
|
|
string orderNo)
|
|
{
|
|
var res = await client.CreateHttpClient()
|
|
.GetStringAsync($"{client.BaseUrl}api/paymentcenter/v1/Payment/QueryOrder?orderNo={orderNo}");
|
|
|
|
return res.FromJsonTo<ApiResult<QueryOrderResponse>>();
|
|
}
|
|
}
|
|
} |