From 5f1c741dc7ecfc26d256b2413cdf54e7c39f47e2 Mon Sep 17 00:00:00 2001
From: zhengyuxuan <zhengyuxuan1995>
Date: 星期三, 19 三月 2025 09:43:36 +0800
Subject: [PATCH] Merge branch 'master' of http://120.26.58.240:8888/r/LifePaymentApi

---
 LifePayment/LifePayment.Domain/Common/CommonManager.cs                   |   13 ------
 LifePayment/LifePayment.Host/LifePaymentServiceHostModule.cs             |    1 
 LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs             |   27 +++++++++++++
 LifePayment/LifePayment.Domain.Shared/ACOOLY/ACOOLYInput.cs              |    5 ++
 LifePayment/LifePayment.Application.Contracts/LifePay/ILifePayService.cs |    2 +
 LifePayment/LifePayment.Host/LifePaymentService.HttpApi.xml              |   11 +++++
 LifePayment/LifePayment.Application/LifePay/LifePayService.cs            |   35 ++++++++++-------
 7 files changed, 68 insertions(+), 26 deletions(-)

diff --git a/LifePayment/LifePayment.Application.Contracts/LifePay/ILifePayService.cs b/LifePayment/LifePayment.Application.Contracts/LifePay/ILifePayService.cs
index d7e405e..70adeed 100644
--- a/LifePayment/LifePayment.Application.Contracts/LifePay/ILifePayService.cs
+++ b/LifePayment/LifePayment.Application.Contracts/LifePay/ILifePayService.cs
@@ -202,6 +202,8 @@
     /// <returns></returns>
     Task<PageOutput<CreateEditPayChannelsInput>> GetLifePayChannlesPage(PageInput input);
 
+    Task<List<CreateEditPayChannelsInput>> GetLifePayChannlesAllList();
+
     Task<CreateEditPayChannelsInput> GetLifePayChannlesDto(Guid id);
 
 
diff --git a/LifePayment/LifePayment.Application/LifePay/LifePayService.cs b/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
index 2ea55a1..2f04efb 100644
--- a/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
+++ b/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
@@ -352,19 +352,12 @@
 
     public async Task<PageOutput<CreateEditPayChannelsInput>> GetLifePayChannlesPage(PageInput input)
     {
+        return await GetLifePayChannlesListFilter().GetPageResult(input.PageModel);
+    }
 
-        return await _lifePayChannlesRep.Select(x =>
-                                                new CreateEditPayChannelsInput
-                                                {
-                                                    Id = x.Id,
-                                                    ChannlesRate = x.ChannlesRate,
-                                                    ChannlesName = x.ChannlesName,
-                                                    ChannlesNum = x.ChannlesNum,
-                                                    Status = x.Status,
-                                                    SwitchType = x.SwitchType,
-                                                    ChannlesType = x.ChannlesType,
-                                                })
-                                            .GetPageResult(input.PageModel);
+    public async Task<List<CreateEditPayChannelsInput>> GetLifePayChannlesAllList()
+    {
+        return await GetLifePayChannlesListFilter().Where(x => x.Status == LifePayChannelsStatsEnum.鍚敤).ToListAsync();
     }
 
     public async Task<CreateEditPayChannelsInput> GetLifePayChannlesDto(Guid id)
@@ -1583,6 +1576,20 @@
         return result;
     }
 
+    private IQueryable<CreateEditPayChannelsInput> GetLifePayChannlesListFilter()
+    {
+        return _lifePayChannlesRep.Select(x =>
+                    new CreateEditPayChannelsInput
+                    {
+                        Id = x.Id,
+                        ChannlesRate = x.ChannlesRate,
+                        ChannlesName = x.ChannlesName,
+                        ChannlesNum = x.ChannlesNum,
+                        Status = x.Status,
+                        SwitchType = x.SwitchType,
+                        ChannlesType = x.ChannlesType,
+                    });
+    }
 
-    #endregion
-}
+        #endregion
+    }
diff --git a/LifePayment/LifePayment.Domain.Shared/ACOOLY/ACOOLYInput.cs b/LifePayment/LifePayment.Domain.Shared/ACOOLY/ACOOLYInput.cs
index 84e4b6d..a09e3dc 100644
--- a/LifePayment/LifePayment.Domain.Shared/ACOOLY/ACOOLYInput.cs
+++ b/LifePayment/LifePayment.Domain.Shared/ACOOLY/ACOOLYInput.cs
@@ -247,6 +247,11 @@
 {
     public string CheckChannelId { get; set; }
 }
+
+public class LogErrorInput
+{
+    public string Error { get; set; }
+}
 public class SetLifePayOrderPayTypeInput : ChannelsBaseInput
 {
     [Required(ErrorMessage = "璁㈠崟鍙蜂笉鍙负绌�")]
diff --git a/LifePayment/LifePayment.Domain/Common/CommonManager.cs b/LifePayment/LifePayment.Domain/Common/CommonManager.cs
index 794b0f5..e9fb433 100644
--- a/LifePayment/LifePayment.Domain/Common/CommonManager.cs
+++ b/LifePayment/LifePayment.Domain/Common/CommonManager.cs
@@ -1,22 +1,11 @@
-锘縰sing LifePayment.Domain.Models;
-using LifePayment.Domain.Shared;
-using Microsoft.Extensions.Configuration;
+锘縰sing Microsoft.Extensions.Configuration;
 using System;
 using System.Net;
 using System.Net.Http;
 using System.Net.Http.Headers;
 using System.Text;
-using System.Text.Json;
 using System.Threading.Tasks;
-using Volo.Abp;
-using Volo.Abp.Domain.Repositories;
 using ZeroD.Util;
-using System.Text.Json.Serialization;
-using System.Text.Json;
-using Aliyun.OSS.Util;
-using Aliyun.OSS;
-using Nest;
-using System.IO;
 
 namespace LifePayment.Domain
 {
diff --git a/LifePayment/LifePayment.Host/LifePaymentService.HttpApi.xml b/LifePayment/LifePayment.Host/LifePaymentService.HttpApi.xml
index 858837f..8fbb84f 100644
--- a/LifePayment/LifePayment.Host/LifePaymentService.HttpApi.xml
+++ b/LifePayment/LifePayment.Host/LifePaymentService.HttpApi.xml
@@ -86,6 +86,12 @@
             </summary>
             <returns></returns>
         </member>
+        <member name="M:LifePayment.HttpApi.LifePayController.AddLogger(LifePayment.Domain.Shared.LogErrorInput)">
+            <summary>
+            娣诲姞鏃ュ織
+            </summary>
+            <returns></returns>
+        </member>
         <member name="M:LifePayment.HttpApi.LifePayController.GetRate">
             <summary>
             鑾峰彇鎶樻墸
@@ -146,6 +152,11 @@
             <param name="input"></param>
             <returns></returns>
         </member>
+        <member name="M:LifePayment.HttpApi.LifePayController.GetLifePayChannlesAllList">
+            <summary>
+            鑾峰彇鍏ㄩ儴缂磋垂娓犻亾
+            </summary>
+        </member>
         <member name="M:LifePayment.HttpApi.LifePayController.GetLifePayChannlesDto(System.Guid)">
             <summary>
             鑾峰彇娓犻亾璇︽儏
diff --git a/LifePayment/LifePayment.Host/LifePaymentServiceHostModule.cs b/LifePayment/LifePayment.Host/LifePaymentServiceHostModule.cs
index 332f441..73175b7 100644
--- a/LifePayment/LifePayment.Host/LifePaymentServiceHostModule.cs
+++ b/LifePayment/LifePayment.Host/LifePaymentServiceHostModule.cs
@@ -150,6 +150,7 @@
                 cacheOptions.GlobalCacheEntryOptions.SlidingExpiration = TimeSpan.FromMinutes(20);
             });
             this.Configure<ACOOLYOption>(configuration.GetSection("ACOOLY"));
+            this.Configure<Config>("AliPayEcsign", configuration.GetSection("AliPayEcsign"));
             this.Configure<InformationOption>(configuration.GetSection("WeiXinCgi"));
         }
 
diff --git a/LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs b/LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs
index 58b03bb..41d72d7 100644
--- a/LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs
+++ b/LifePayment/LifePayment.HttpApi/LifePay/LifePayController.cs
@@ -2,6 +2,7 @@
 using LifePayment.Domain.Shared;
 using Microsoft.AspNetCore.Authorization;
 using Microsoft.AspNetCore.Mvc;
+using Microsoft.Extensions.Logging;
 using System;
 using System.Collections.Generic;
 using System.Linq;
@@ -20,13 +21,16 @@
     {
         private readonly ILifePayService _lifePayService;
         private readonly IWebClientInfoProvider _webClientInfoProvider;
+        private readonly ILogger<LifePayController> _logger;
         public LifePayController(
               ILifePayService lifePayService,
               IWebClientInfoProvider webClientInfoProvider
+            , ILogger<LifePayController> logger
               )
         {
             _lifePayService = lifePayService;
             _webClientInfoProvider = webClientInfoProvider;
+            _logger = logger;
         }
 
         #region 鏌ヨ
@@ -105,6 +109,20 @@
         {
             return await _lifePayService.GetGasOrgType();
         }
+
+        /// <summary>
+        /// 娣诲姞鏃ュ織
+        /// </summary>
+        /// <returns></returns>
+        [HttpPost]
+        [AllowAnonymous]
+
+        public async Task<int> AddLogger(LogErrorInput input)
+        {
+            Logger.LogError("鍓嶇閿欒锛�" + input.Error);
+            return Constant.SUCCESS;
+        }
+
 
         /// <summary>
         /// 鑾峰彇鎶樻墸
@@ -213,6 +231,15 @@
         }
 
         /// <summary>
+        /// 鑾峰彇鍏ㄩ儴缂磋垂娓犻亾
+        /// </summary>
+        [HttpGet]
+        public async Task<List<CreateEditPayChannelsInput>> GetLifePayChannlesAllList()
+        {
+            return await _lifePayService.GetLifePayChannlesAllList();
+        }
+
+        /// <summary>
         /// 鑾峰彇娓犻亾璇︽儏
         /// </summary>
         /// <param name="id"></param>

--
Gitblit v1.9.1