|
@@ -0,0 +1,43 @@
|
|
|
+using System;
|
|
|
+using System.Collections.Generic;
|
|
|
+using System.Linq;
|
|
|
+using Microsoft.AspNetCore.Mvc;
|
|
|
+using Microsoft.AspNetCore.Http;
|
|
|
+using Microsoft.Extensions.Logging;
|
|
|
+using Microsoft.Extensions.Options;
|
|
|
+using Microsoft.AspNetCore.Authorization;
|
|
|
+using System.Web;
|
|
|
+using MySystem.MainModels;
|
|
|
+using LitJson;
|
|
|
+using Library;
|
|
|
+using System.IO;
|
|
|
+
|
|
|
+namespace MySystem.Areas.Api.Controllers.v1
|
|
|
+{
|
|
|
+ [Area("Api")]
|
|
|
+ [Route("Api/[controller]/[action]")]
|
|
|
+ public class AlipayController : BaseController
|
|
|
+ {
|
|
|
+ public AlipayController(IHttpContextAccessor accessor, ILogger<BaseController> logger, IOptions<Setting> setting) : base(accessor, logger, setting)
|
|
|
+ {
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ #region 支付宝服务平台支付回调
|
|
|
+ public Dictionary<string, string> Notice()
|
|
|
+ {
|
|
|
+ StreamReader sr = new StreamReader(Request.Body);
|
|
|
+ string requestMes = sr.ReadToEnd();
|
|
|
+ function.WriteLog(DateTime.Now.ToString() + "\r\n" + requestMes + "\r\n\r\n", "支付宝服务平台支付回调");
|
|
|
+ RedisDbconn.Instance.AddList("PayCallBack", requestMes);
|
|
|
+ Dictionary<string, string> dic = new Dictionary<string, string>();
|
|
|
+ dic.Add("code", "SUCCESS");
|
|
|
+ dic.Add("message", "");
|
|
|
+ return dic;
|
|
|
+ }
|
|
|
+ #endregion
|
|
|
+
|
|
|
+ }
|
|
|
+}
|