LifePayment/LifePayment.Application.Contracts/User/IAccountService.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
LifePayment/LifePayment.Application.Contracts/User/QrCodeLogin.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
LifePayment/LifePayment.Application/User/AccountService.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
LifePayment/LifePayment.Host/LifePaymentService.HttpApi.xml | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
LifePayment/LifePayment.Host/LifePaymentServices.Application.Contracts.xml | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
LifePayment/LifePayment.HttpApi/LifePay/AccountController.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
LifePayment/LifePayment.HttpApi/LifePay/ChannelFilterAttribute.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
LifePayment/LifePayment.Application.Contracts/User/IAccountService.cs
New file @@ -0,0 +1,25 @@ using System; using System.Threading.Tasks; using Volo.Abp; using Volo.Abp.Application.Services; namespace LifePayment.Application.Contracts { public interface IAccountService : IApplicationService { #region life pay /// <summary> /// 手机验证码登录 /// 版本说明:使用验证码管理去校验和失效对应业务的验证码 /// </summary> /// <param name="input"></param> /// <returns></returns> /// <exception cref="UserFriendlyException"></exception> Task<Guid> LifePayPhoneMesssageCodeLogin(LifePayPhoneMesssageCodeLoginInput input); #endregion } } LifePayment/LifePayment.Application.Contracts/User/QrCodeLogin.cs
New file @@ -0,0 +1,27 @@ using LifePayment.Domain.Shared; using System.ComponentModel; using System.ComponentModel.DataAnnotations; namespace LifePayment.Application.Contracts { public class LifePayPhoneMesssageCodeLoginInput : ChannelsBaseInput { /// <summary> /// 手机号 /// </summary> [DisplayName("手机号")] [Required(ErrorMessage = "{0}不能为空")] [RegularExpression(LifePaymentConstant.RegularExpression.PhoneNumberRegEx, ErrorMessage = "{0}格式错误")] public string PhoneNumber { get; set; } /// <summary> /// 验证码 /// </summary> //[Required] //public string Code { get; set; } } } LifePayment/LifePayment.Application/User/AccountService.cs
New file @@ -0,0 +1,88 @@ using LifePayment.Application.Contracts; using LifePayment.Domain.Models; using Microsoft.EntityFrameworkCore; using System; using System.Linq; using System.Threading.Tasks; using Volo.Abp; using Volo.Abp.Application.Services; using Volo.Abp.Domain.Repositories; using ZeroD.Util; namespace HumanResourcesServices.Application { public class AccountService : ApplicationService, IAccountService { private readonly IRepository<LifePayUser, Guid> _lifePayUserRepository; public AccountService( IRepository<LifePayUser, Guid> lifePayUserRepository ) { _lifePayUserRepository = lifePayUserRepository; } #region 查询 #endregion #region 操作 #region life pay /// <summary> /// 手机验证码登录 /// 版本说明:使用验证码管理去校验和失效对应业务的验证码 /// </summary> /// <param name="input"></param> /// <returns></returns> /// <exception cref="UserFriendlyException"></exception> public async Task<Guid> LifePayPhoneMesssageCodeLogin(LifePayPhoneMesssageCodeLoginInput input) { //var vcodeType = VerificationCodeBusinessTypeEnum.LifePayPhoneMesssageCodeLogin; //var checkResult = await _verificationCodeManager.CheckVerificationCodeByBusinessType(vcodeType, // input.PhoneNumber, // input.Code, // true); //CheckExtensions.IfTrueThrowUserFriendlyException(!checkResult, // CustomeErrorMessage.SometingWrongOrSometing, "验证码", "已失效"); var lifeUser = await _lifePayUserRepository.Where(x => x.PhoneNumber == input.PhoneNumber).FirstOrDefaultAsync(); if (lifeUser == null) { lifeUser = new LifePayUser() { Id = GuidGenerator.Create(), PhoneNumber = input.PhoneNumber, LastLoginTime = DateTime.Now }; await _lifePayUserRepository.InsertAsync(lifeUser); } else { lifeUser.LastLoginTime = DateTime.Now; await _lifePayUserRepository.UpdateAsync(lifeUser); } return lifeUser.Id; } #endregion #endregion } } LifePayment/LifePayment.Host/LifePaymentService.HttpApi.xml
@@ -4,21 +4,41 @@ <name>LifePayment.HttpApi</name> </assembly> <members> <member name="M:LifePayment.HttpApi.LifePayController.GetElectricParValue"> <member name="M:LifePayment.HttpApi.AccountController.LifePayPhoneMesssageCodeLogin(LifePayment.Application.Contracts.LifePayPhoneMesssageCodeLoginInput)"> <summary> life pay手机验证码登录 </summary> <param name="input"></param> <returns></returns> <exception cref="T:Volo.Abp.UserFriendlyException"></exception> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetElectricParValue(LifePayment.Domain.Shared.ChannelsBaseInput)"> <summary> 获取电费面值 </summary> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetElectricSupportArea"> <member name="M:LifePayment.HttpApi.LifePayController.GetElectricSupportArea(LifePayment.Domain.Shared.ChannelsBaseInput)"> <summary> 获取电费充值区域 </summary> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetPhoneParValue"> <member name="M:LifePayment.HttpApi.LifePayController.GetPhoneParValue(LifePayment.Domain.Shared.ChannelsBaseInput)"> <summary> 获取话费面值 </summary> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetGasParValue(LifePayment.Domain.Shared.ChannelsBaseInput)"> <summary> 获取燃气面值 </summary> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetGasOrgType(LifePayment.Domain.Shared.ChannelsBaseInput)"> <summary> 获取燃气支持商户 </summary> <returns></returns> </member> @@ -49,11 +69,75 @@ <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetPayStatusByOrderNo(System.String)"> <member name="M:LifePayment.HttpApi.LifePayController.GetUserLifePayOrderDetail(System.String)"> <summary> 获取我的订单详情 </summary> <param name="orderNo"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetPayStatusByOrderNo(LifePayment.Application.Contracts.GetPayStatusByOrderNoInput)"> <summary> 根据订单号获取支付状态 </summary> <param name="orderNo"></param> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetLifePayChannlesPage(ZeroD.Util.PageInput)"> <summary> 获取缴费渠道列表 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetLifePayChannlesDto(System.Guid)"> <summary> 获取渠道详情 </summary> <param name="id"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetUserLifePayOrderRefund(System.Guid)"> <summary> 用户查看生活缴费退款失败详情 </summary> <param name="id"></param> <returns></returns> <exception cref="T:Volo.Abp.UserFriendlyException"></exception> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetAccountPage(LifePayment.Application.Contracts.QueryUserAccountListInput)"> <summary> 获取用户户号分页数据 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetUserAccountList(LifePayment.Application.Contracts.QueryUserAccountListInput)"> <summary> 获取我的户号列表 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetUserAccountAllList(LifePayment.Application.Contracts.QueryUserAccountAllListInput)"> <summary> 获取我的全部户号列表 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetUserAccountDetail(System.Guid)"> <summary> 获取我的户号详情 </summary> <param name="id"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.GetLifePayOrderPageExport(LifePayment.Application.Contracts.QueryLifePayOrderListInput)"> <summary> 导出订单Excel </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.CreateLifePayPhoneOrder(LifePayment.Application.Contracts.CreateLifePayOrderInput{LifePayment.Application.Contracts.LifePhoneData})"> @@ -70,6 +154,13 @@ <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.CreateLifePayGasOrder(LifePayment.Application.Contracts.CreateLifePayOrderInput{LifePayment.Application.Contracts.LifeGasData})"> <summary> 创建生活缴费燃气订单 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.RefundLifePayOrder(LifePayment.Application.Contracts.RefundLifePayOrderInput)"> <summary> 退款生活缴费订单 @@ -78,6 +169,57 @@ <returns></returns> <exception cref="T:Volo.Abp.UserFriendlyException"></exception> </member> <member name="M:LifePayment.HttpApi.LifePayController.RefundUserLifePayOrder(LifePayment.Application.Contracts.RefundUserLifePayOrderInput)"> <summary> 用户发起生活缴费退款 </summary> <param name="input"></param> <returns></returns> <exception cref="T:Volo.Abp.UserFriendlyException"></exception> </member> <member name="M:LifePayment.HttpApi.LifePayController.AddUpdateUserAccount(LifePayment.Application.Contracts.AddUpdateUserAccountInput)"> <summary> 添加或修改我的户号 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.DeleteUserAccount(System.Guid)"> <summary> 删除我的户号 </summary> <param name="id"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.RejectRefundLifePayOrder(LifePayment.Application.Contracts.RefundLifePayOrderInput)"> <summary> 退款驳回 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.CreateEditPayChannels(LifePayment.Application.Contracts.CreateEditPayChannelsInput)"> <summary> 渠道管理 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.SetLifePayChannelsStatus(System.Guid,LifePayment.Domain.Shared.LifePayChannelsStatsEnum)"> <summary> 设置渠道启用状态 </summary> <param name="id"></param> <param name="status"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.CreateEditLifePayRate(System.Collections.Generic.List{LifePayment.Application.Contracts.LifePayRateInput})"> <summary> 折扣配置 </summary> <param name="input"></param> <returns></returns> </member> <member name="M:LifePayment.HttpApi.LifePayController.SetLifePayOrderPayType(LifePayment.Domain.Shared.SetLifePayOrderPayTypeInput)"> <summary> 设置生活缴费支付类型 LifePayment/LifePayment.Host/LifePaymentServices.Application.Contracts.xml
@@ -763,5 +763,19 @@ 用户id </summary> </member> <member name="M:LifePayment.Application.Contracts.IAccountService.LifePayPhoneMesssageCodeLogin(LifePayment.Application.Contracts.LifePayPhoneMesssageCodeLoginInput)"> <summary> 手机验证码登录 版本说明:使用验证码管理去校验和失效对应业务的验证码 </summary> <param name="input"></param> <returns></returns> <exception cref="T:Volo.Abp.UserFriendlyException"></exception> </member> <member name="P:LifePayment.Application.Contracts.LifePayPhoneMesssageCodeLoginInput.PhoneNumber"> <summary> 手机号 </summary> </member> </members> </doc> LifePayment/LifePayment.HttpApi/LifePay/AccountController.cs
New file @@ -0,0 +1,57 @@ using LifePayment.Application.Contracts; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Microsoft.Extensions.Options; using System; using System.Threading.Tasks; using Volo.Abp; using Volo.Abp.AspNetCore.Mvc; using Volo.Abp.AspNetCore.WebClientInfo; namespace LifePayment.HttpApi { [Route("api/[controller]/[action]")] [ApiController] public class AccountController : AbpController { private readonly IAccountService _accountService; private readonly IWebClientInfoProvider _webClientInfoProvider; public AccountController( IAccountService accountService, IWebClientInfoProvider webClientInfoProvider ) { _accountService = accountService; _webClientInfoProvider = webClientInfoProvider; } #region life pay /// <summary> /// life pay手机验证码登录 /// </summary> /// <param name="input"></param> /// <returns></returns> /// <exception cref="UserFriendlyException"></exception> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<Guid> LifePayPhoneMesssageCodeLogin(LifePayPhoneMesssageCodeLoginInput input) { return await _accountService.LifePayPhoneMesssageCodeLogin(input); } #endregion } } LifePayment/LifePayment.HttpApi/LifePay/ChannelFilterAttribute.cs
New file @@ -0,0 +1,59 @@ using LifePayment.Application.Contracts; using LifePayment.Domain.Shared; using Microsoft.AspNetCore.Mvc.Abstractions; using Microsoft.AspNetCore.Mvc.Filters; using System; using System.Threading.Tasks; using Volo.Abp; using Volo.Abp.AspNetCore.Mvc; namespace LifePayment.HttpApi { public class ChannelFilterAttribute : Attribute, IAsyncActionFilter { public ChannelFilterAttribute() { } public async Task OnActionExecutionAsync(ActionExecutingContext context, ActionExecutionDelegate next) { if (!context.ActionDescriptor.IsControllerAction()) { await next(); return; } var checkerService = context.GetRequiredService<ILifePayService>(); foreach (var argument in context.ActionArguments) { // 检查参数类型是否为 ChannelsBaseInput if (argument.Value is ChannelsBaseInput model) { // 获取 Channel 参数的值 string channelValue = model.CheckChannelId; if (!string.IsNullOrEmpty(channelValue)) { var result = await checkerService.CheckChannelsStatus(channelValue); if (result) { await next(); } else { throw new UserFriendlyException("没有对应的渠道"); } } } } } } } LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs
@@ -1,9 +1,7 @@ using LifePayment.Application.Contracts; using LifePayment.Domain; using LifePayment.Domain.Shared; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Newtonsoft.Json; using System; using System.Collections.Generic; using System.Linq; @@ -11,12 +9,7 @@ using Volo.Abp; using Volo.Abp.AspNetCore.Mvc; using Volo.Abp.AspNetCore.WebClientInfo; using Volo.Abp.EventBus.Distributed; using Volo.Abp.Identity; using Volo.Abp.Uow; using ZeroD.Util; using ZeroD.Util.Fadd; using LifePayment.Application.Contracts; namespace LifePayment.HttpApi { @@ -42,9 +35,10 @@ /// 获取电费面值 /// </summary> /// <returns></returns> [HttpGet] [HttpPost] [AllowAnonymous] public async Task<ElectricParValueResponse> GetElectricParValue() [ChannelFilter] public async Task<ElectricParValueResponse> GetElectricParValue(ChannelsBaseInput input) { return await _lifePayService.GetElectricParValue(); } @@ -53,17 +47,18 @@ /// 获取电费充值区域 /// </summary> /// <returns></returns> [HttpGet] [HttpPost] [AllowAnonymous] public async Task<ElectricSupportAreaResponse> GetElectricSupportArea() [ChannelFilter] public async Task<ElectricSupportAreaResponse> GetElectricSupportArea(ChannelsBaseInput input) { var aresResult = await _lifePayService.GetElectricSupportArea(); var parValues = await _lifePayService.GetElectricParValue(); foreach(var item in aresResult.ElectricAreaList) foreach (var item in aresResult.ElectricAreaList) { var paritem = parValues.ElectricParValue.Where(r=>r.AreaName == item.CityName).FirstOrDefault(); if(paritem != null) var paritem = parValues.ElectricParValue.Where(r => r.AreaName == item.CityName).FirstOrDefault(); if (paritem != null) { item.ElectricType = paritem.ElectricType; item.ParValue = paritem.ParValue; @@ -78,11 +73,36 @@ /// 获取话费面值 /// </summary> /// <returns></returns> [HttpGet] [HttpPost] [AllowAnonymous] public async Task<PhoneParValueResponse> GetPhoneParValue() [ChannelFilter] public async Task<PhoneParValueResponse> GetPhoneParValue(ChannelsBaseInput input) { return await _lifePayService.GetPhoneParValue(); } /// <summary> /// 获取燃气面值 /// </summary> /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<GasParValueResponse> GetGasParValue(ChannelsBaseInput input) { return await _lifePayService.GetGasParValue(); } /// <summary> /// 获取燃气支持商户 /// </summary> /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<GasOrgTypeValueResponse> GetGasOrgType(ChannelsBaseInput input) { return await _lifePayService.GetGasOrgType(); } /// <summary> @@ -125,21 +145,138 @@ /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<PageOutput<UserLifePayOrderOutput>> GetUserLifePayOrderPage(QueryLifePayOrderListInput input) { return await _lifePayService.GetUserLifePayOrderPage(input); } /// <summary> /// 根据订单号获取支付状态 /// 获取我的订单详情 /// </summary> /// <param name="orderNo"></param> /// <returns></returns> [HttpGet] [AllowAnonymous] public async Task<LifePayStatusEnum> GetPayStatusByOrderNo(string orderNo) public async Task<UserLifePayOrderOutput> GetUserLifePayOrderDetail(string orderNo) { return await _lifePayService.GetPayStatusByOrderNo(orderNo); return await _lifePayService.GetUserLifePayOrderDetail(orderNo); } /// <summary> /// 根据订单号获取支付状态 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<LifePayStatusEnum> GetPayStatusByOrderNo(GetPayStatusByOrderNoInput input) { return await _lifePayService.GetPayStatusByOrderNo(input.OrderNo); } /// <summary> /// 获取缴费渠道列表 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] public async Task<PageOutput<CreateEditPayChannelsInput>> GetLifePayChannlesPage(PageInput input) { return await _lifePayService.GetLifePayChannlesPage(input); } /// <summary> /// 获取渠道详情 /// </summary> /// <param name="id"></param> /// <returns></returns> [HttpGet] public async Task<CreateEditPayChannelsInput> GetLifePayChannlesDto(Guid id) { return await _lifePayService.GetLifePayChannlesDto(id); } /// <summary> /// 用户查看生活缴费退款失败详情 /// </summary> /// <param name="id"></param> /// <returns></returns> /// <exception cref="UserFriendlyException"></exception> [HttpGet] [AllowAnonymous] public async Task<UserLifePayOrderRefundOutput> GetUserLifePayOrderRefund(Guid id) { return await _lifePayService.GetUserLifePayOrderRefund(id); } /// <summary> /// 获取用户户号分页数据 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] public async Task<PageOutput<UserAccountOutput>> GetAccountPage(QueryUserAccountListInput input) { return await _lifePayService.GetAccountPage(input); } /// <summary> /// 获取我的户号列表 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<PageOutput<UserAccountOutput>> GetUserAccountList(QueryUserAccountListInput input) { return await _lifePayService.GetUserAccountList(input); } /// <summary> /// 获取我的全部户号列表 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<List<UserAccountOutput>> GetUserAccountAllList(QueryUserAccountAllListInput input) { return await _lifePayService.GetUserAccountAllList(input); } /// <summary> /// 获取我的户号详情 /// </summary> /// <param name="id"></param> /// <returns></returns> [HttpGet] [AllowAnonymous] public async Task<UserAccountOutput> GetUserAccountDetail(Guid id) { return await _lifePayService.GetUserAccountDetail(id); } /// <summary> /// 导出订单Excel /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] public async Task<ActionResult> GetLifePayOrderPageExport(QueryLifePayOrderListInput input) { var data = await _lifePayService.GetLifePayOrderPageExport(input); if (data.Any()) { var bytes = ExcelHelper.ListToByteForExcel(data, "xlsx"); return File(bytes, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", "订单管理" + ".xlsx"); } return Json(default); } #endregion @@ -153,6 +290,7 @@ /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<CreateLifePayOrderOutput> CreateLifePayPhoneOrder(CreateLifePayOrderInput<LifePhoneData> input) { return await _lifePayService.CreateLifePayPhoneOrder(input); @@ -165,9 +303,23 @@ /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<CreateLifePayOrderOutput> CreateLifePayElectricOrder(CreateLifePayOrderInput<LifeElectricData> input) { return await _lifePayService.CreateLifePayElectricOrder(input); } /// <summary> /// 创建生活缴费燃气订单 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<CreateLifePayOrderOutput> CreateLifePayGasOrder(CreateLifePayOrderInput<LifeGasData> input) { return await _lifePayService.CreateLifePayGasOrder(input); } /// <summary> @@ -184,12 +336,104 @@ } /// <summary> /// 用户发起生活缴费退款 /// </summary> /// <param name="input"></param> /// <returns></returns> /// <exception cref="UserFriendlyException"></exception> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<int> RefundUserLifePayOrder(RefundUserLifePayOrderInput input) { await _lifePayService.RefundUserLifePayOrder(input); return Constant.SUCCESS; } /// <summary> /// 添加或修改我的户号 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<int> AddUpdateUserAccount(AddUpdateUserAccountInput input) { await _lifePayService.AddUpdateUserAccount(input); return Constant.SUCCESS; } /// <summary> /// 删除我的户号 /// </summary> /// <param name="id"></param> /// <returns></returns> [HttpPost] [AllowAnonymous] public async Task<int> DeleteUserAccount(Guid id) { await _lifePayService.DeleteUserAccount(id); return Constant.SUCCESS; } /// <summary> /// 退款驳回 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] public async Task<int> RejectRefundLifePayOrder(RefundLifePayOrderInput input) { await _lifePayService.RejectRefundLifePayOrder(input); return Constant.SUCCESS; } /// <summary> /// 渠道管理 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] public async Task<int> CreateEditPayChannels(CreateEditPayChannelsInput input) { await _lifePayService.CreateEditPayChannels(input); return Constant.SUCCESS; } /// <summary> /// 设置渠道启用状态 /// </summary> /// <param name="id"></param> /// <param name="status"></param> /// <returns></returns> [HttpGet] public async Task<int> SetLifePayChannelsStatus(Guid id, LifePayChannelsStatsEnum status) { await _lifePayService.SetLifePayChannelsStatus(id, status); return Constant.SUCCESS; } /// <summary> /// 折扣配置 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] public async Task<int> CreateEditLifePayRate(List<LifePayRateInput> input) { await _lifePayService.CreateEditLifePayRate(input); return Constant.SUCCESS; } /// <summary> /// 设置生活缴费支付类型 /// </summary> /// <param name="input"></param> /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<string> SetLifePayOrderPayType(SetLifePayOrderPayTypeInput input) { @@ -203,6 +447,7 @@ /// <returns></returns> [HttpPost] [AllowAnonymous] [ChannelFilter] public async Task<ModelPaymentMiniPay> GetPayOrderForJsAPI(GetPayOrderForJsAPIInput input) { return await _lifePayService.GetPayOrderForJsAPI(input, _webClientInfoProvider.ClientIpAddress);