mirror of
https://gitee.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat.git
synced 2025-09-20 10:38:10 +08:00
chore(tenpayv3): 新增基于 .NET Framework 4.7 的示例项目
This commit is contained in:
@@ -1,19 +1,16 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.Extensions.Options;
|
||||
using SKIT.FlurlHttpClient.Wechat.TenpayV3;
|
||||
using SKIT.FlurlHttpClient.Wechat.TenpayV3.Models;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.Sample_Net5.Controllers
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.Sample.Controllers
|
||||
{
|
||||
using SKIT.FlurlHttpClient.Wechat.TenpayV3;
|
||||
using SKIT.FlurlHttpClient.Wechat.TenpayV3.Models;
|
||||
|
||||
[ApiController]
|
||||
[Route("order")]
|
||||
[Route("api/order")]
|
||||
public class TenpayOrderController : ControllerBase
|
||||
{
|
||||
private readonly ILogger _logger;
|
||||
@@ -34,9 +31,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.Sample_Net5.Controllers
|
||||
[Route("jsapi")]
|
||||
public async Task<IActionResult> CreateOrderByJsapi([FromBody] Models.CreateOrderByJsapiRequest requestModel)
|
||||
{
|
||||
// JSAPI 下单
|
||||
// 文档:https://pay.weixin.qq.com/wiki/doc/apiv3/apis/chapter3_1_1.shtml
|
||||
|
||||
var client = _tenpayHttpClientFactory.Create(requestModel.MerchantId);
|
||||
var request = new CreatePayTransactionJsapiRequest()
|
||||
{
|
||||
|
Reference in New Issue
Block a user