From bda2679db0d10a0328a71ff4f55f000d26ef10dc Mon Sep 17 00:00:00 2001
From: zhengyuxuan <zhengyuxuan1995>
Date: 星期五, 21 三月 2025 14:51:32 +0800
Subject: [PATCH] fix:bug修复
---
LifePayment/LifePayment.Application.Contracts/LifePay/LifePayOutput.cs | 29 ++++++++++----
LifePayment/LifePayment.Host/LifePaymentServices.Application.Contracts.xml | 25 ++++++++++++
LifePayment/LifePayment.Domain/LifePay/DallyStatistics.cs | 28 ++++++++------
LifePayment/LifePayment.Application/LifePay/LifePayService.cs | 22 ++++++-----
4 files changed, 73 insertions(+), 31 deletions(-)
diff --git a/LifePayment/LifePayment.Application.Contracts/LifePay/LifePayOutput.cs b/LifePayment/LifePayment.Application.Contracts/LifePay/LifePayOutput.cs
index 40853ad..54f3991 100644
--- a/LifePayment/LifePayment.Application.Contracts/LifePay/LifePayOutput.cs
+++ b/LifePayment/LifePayment.Application.Contracts/LifePay/LifePayOutput.cs
@@ -763,6 +763,11 @@
public decimal? ActualRechargeAmount { get; set; }
/// <summary>
+ /// 瀹為檯鍒拌处閲戦
+ /// </summary>
+ public decimal? ActualReceivedAmount { get; set; }
+
+ /// <summary>
/// 閫�娆鹃噾棰�
/// </summary>
public decimal? RefundPrice { get; set; }
@@ -866,46 +871,52 @@
/// <summary>
/// 璐︽埛浣欓
/// </summary>
- public string Amount { get; set; }
+ public decimal Amount { get; set; }
/// <summary>
/// 绱鏀舵
/// </summary>
- public string AccumulatedReceipts { get; set; }
+ public decimal AccumulatedReceipts { get; set; }
/// <summary>
/// 鏄ㄦ棩鏀舵
/// </summary>
- public string ReceiptsYesterda { get; set; }
+ public decimal ReceiptsYesterda { get; set; }
+
+
+ /// <summary>
+ /// 绱鏀跺叆
+ /// </summary>
+ public decimal AccumulatedIncome { get; set; }
/// <summary>
/// 绱涓嬪崟
/// </summary>
- public string AccumulatedOrders { get; set; }
+ public int AccumulatedOrders { get; set; }
/// <summary>
/// 鏄ㄦ棩涓嬪崟
/// </summary>
- public string OrdersNumYesterda { get; set; }
+ public int OrdersNumYesterda { get; set; }
/// <summary>
/// 鏄ㄦ棩鎴愬姛
/// </summary>
- public string YesterdaSuccess { get; set; }
+ public int YesterdaSuccess { get; set; }
/// <summary>
/// 鏄ㄦ棩澶辫触
/// </summary>
- public string YesterdaFail { get; set; }
+ public int YesterdaFail { get; set; }
/// <summary>
/// 绱鐢ㄦ埛
/// </summary>
- public string AccumulatedUsers { get; set; }
+ public int AccumulatedUsers { get; set; }
/// <summary>
/// 鏄ㄦ棩娲昏穬鐢ㄦ埛
/// </summary>
- public string YesterdayActiveUsers { get; set; }
+ public int YesterdayActiveUsers { get; set; }
}
\ No newline at end of file
diff --git a/LifePayment/LifePayment.Application/LifePay/LifePayService.cs b/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
index ff3ef8a..e24db15 100644
--- a/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
+++ b/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
@@ -102,6 +102,7 @@
var accumulatedReceipts = await _lifePayOrderRepository.Where(x => x.CreationTime < today).SumAsync(x => x.PayAmount);
var receiptsYesterday = await _lifePayOrderRepository.Where(x => x.CreationTime >= today.AddDays(-1) && x.CreationTime < today).SumAsync(x => x.PayAmount);
var accumulatedOrders = await _lifePayOrderRepository.Where(x => x.CreationTime < today).CountAsync();
+ var accumulatedIncome = await _lifePayOrderRepository.Where(x => x.CreationTime < today).SumAsync(x => x.ActualRechargeAmount);
var ordersNumYesterday = await _lifePayOrderRepository.Where(x => x.CreationTime >= today.AddDays(-1) && x.CreationTime < today).CountAsync();
var yesterdaySuccess = await _lifePayOrderRepository.Where(x => x.CreationTime >= today.AddDays(-1) && x.CreationTime < today && x.LifePayOrderStatus == LifePayOrderStatusEnum.宸插畬鎴�).CountAsync();
var yesterdayFail = await _lifePayOrderRepository.Where(x => x.CreationTime >= today.AddDays(-1) && x.CreationTime < today && x.LifePayOrderStatus == LifePayOrderStatusEnum.宸插け璐�).CountAsync();
@@ -111,18 +112,18 @@
{
Id = GuidGenerator.Create(),
CreationTime = DateTime.Now,
- Amount = "0",
- AccumulatedReceipts = accumulatedReceipts.ToString(),
- ReceiptsYesterday = receiptsYesterday.ToString(),
- AccumulatedOrders = accumulatedOrders.ToString(),
- OrdersNumYesterday = ordersNumYesterday.ToString(),
- YesterdaySuccess = yesterdaySuccess.ToString(),
- YesterdayFail = yesterdayFail.ToString(),
- AccumulatedUsers = accumulatedUsers.ToString(),
+ Amount = 0,
+ AccumulatedReceipts = accumulatedReceipts,
+ ReceiptsYesterday = receiptsYesterday,
+ AccumulatedOrders = accumulatedOrders,
+ OrdersNumYesterday = ordersNumYesterday,
+ YesterdaySuccess = yesterdaySuccess,
+ YesterdayFail = yesterdayFail,
+ AccumulatedUsers = accumulatedUsers,
};
await _dallyStatisticsRepository.InsertAsync(entity);
- var result = ObjectMapper.Map<DallyStatistics, TopStatisticsOutput>(entity);
- return result;
+ //var result = ObjectMapper.Map<DallyStatistics, TopStatisticsOutput>(entity);
+ return new TopStatisticsOutput();
}
else
{
@@ -466,6 +467,7 @@
ACOOLYOrderNo = order.ACOOLYOrderNo,
LifePayRefundStatus = order.LifePayRefundStatus,
ActualRechargeAmount = order.ActualRechargeAmount,
+ ActualReceivedAmount = order.ActualReceivedAmount,
RefundPrice = order.RefundPrice,
ElecBillUrl = order.ElecBillUrl.GetOssPath(),
RefundElecBillUrl = order.RefundElecBillUrl.GetOssPath(),
diff --git a/LifePayment/LifePayment.Domain/LifePay/DallyStatistics.cs b/LifePayment/LifePayment.Domain/LifePay/DallyStatistics.cs
index 8907ba1..eeb5cbe 100644
--- a/LifePayment/LifePayment.Domain/LifePay/DallyStatistics.cs
+++ b/LifePayment/LifePayment.Domain/LifePay/DallyStatistics.cs
@@ -9,53 +9,57 @@
public class DallyStatistics : Entity<Guid>
{
- /// <summary>
- /// 缁熻鏃堕棿
- /// </summary>
+
public DateTime CreationTime { get; set; }
/// <summary>
/// 璐︽埛浣欓
/// </summary>
- public string Amount { get; set; }
+ public decimal Amount { get; set; }
/// <summary>
/// 绱鏀舵
/// </summary>
- public string AccumulatedReceipts { get; set; }
+ public decimal AccumulatedReceipts { get; set; }
/// <summary>
/// 鏄ㄦ棩鏀舵
/// </summary>
- public string ReceiptsYesterday { get; set; }
+ public decimal ReceiptsYesterday { get; set; }
+
+
+ /// <summary>
+ /// 绱鏀跺叆
+ /// </summary>
+ public decimal AccumulatedIncome { get; set; }
/// <summary>
/// 绱涓嬪崟
/// </summary>
- public string AccumulatedOrders { get; set; }
+ public int AccumulatedOrders { get; set; }
/// <summary>
/// 鏄ㄦ棩涓嬪崟
/// </summary>
- public string OrdersNumYesterday { get; set; }
+ public int OrdersNumYesterday { get; set; }
/// <summary>
/// 鏄ㄦ棩鎴愬姛
/// </summary>
- public string YesterdaySuccess { get; set; }
+ public int YesterdaySuccess { get; set; }
/// <summary>
/// 鏄ㄦ棩澶辫触
/// </summary>
- public string YesterdayFail { get; set; }
+ public int YesterdayFail { get; set; }
/// <summary>
/// 绱鐢ㄦ埛
/// </summary>
- public string AccumulatedUsers { get; set; }
+ public int AccumulatedUsers { get; set; }
/// <summary>
/// 鏄ㄦ棩娲昏穬鐢ㄦ埛
/// </summary>
- public string YesterdayActiveUsers { get; set; }
+ public int YesterdayActiveUsers { get; set; }
}
\ No newline at end of file
diff --git a/LifePayment/LifePayment.Host/LifePaymentServices.Application.Contracts.xml b/LifePayment/LifePayment.Host/LifePaymentServices.Application.Contracts.xml
index c4bc189..c1e0de8 100644
--- a/LifePayment/LifePayment.Host/LifePaymentServices.Application.Contracts.xml
+++ b/LifePayment/LifePayment.Host/LifePaymentServices.Application.Contracts.xml
@@ -740,6 +740,11 @@
閫�娆惧嚟璇�
</summary>
</member>
+ <member name="P:LifePayment.Application.Contracts.LifePayOrderListOutput.RefundPrice">
+ <summary>
+ 閫�娆鹃噾棰�
+ </summary>
+ </member>
<member name="P:LifePayment.Application.Contracts.LifePayOrderListOutput.CreationTime">
<summary>
涓嬪崟鏃堕棿
@@ -1060,6 +1065,11 @@
鍥炲崟鍦板潃
</summary>
</member>
+ <member name="P:LifePayment.Application.Contracts.LifePayOrderOutput.RefundElecBillUrl">
+ <summary>
+ 閫�娆惧洖鍗曞湴鍧�
+ </summary>
+ </member>
<member name="P:LifePayment.Application.Contracts.LifePayRefundOrderOutput.UserPhoneNumber">
<summary>
鐢ㄦ埛璐﹀彿
@@ -1170,6 +1180,11 @@
瀹為檯鍏呭�奸噾棰�
</summary>
</member>
+ <member name="P:LifePayment.Application.Contracts.LifePayRefundOrderOutput.ActualReceivedAmount">
+ <summary>
+ 瀹為檯鍒拌处閲戦
+ </summary>
+ </member>
<member name="P:LifePayment.Application.Contracts.LifePayRefundOrderOutput.RefundPrice">
<summary>
閫�娆鹃噾棰�
@@ -1178,6 +1193,11 @@
<member name="P:LifePayment.Application.Contracts.LifePayRefundOrderOutput.ElecBillUrl">
<summary>
鍥炲崟鍦板潃
+ </summary>
+ </member>
+ <member name="P:LifePayment.Application.Contracts.LifePayRefundOrderOutput.RefundElecBillUrl">
+ <summary>
+ 閫�娆惧洖鍗曞湴鍧�
</summary>
</member>
<member name="P:LifePayment.Application.Contracts.UserLifePayOrderRefundOutput.Id">
@@ -1260,6 +1280,11 @@
鏄ㄦ棩鏀舵
</summary>
</member>
+ <member name="P:LifePayment.Application.Contracts.TopStatisticsOutput.AccumulatedIncome">
+ <summary>
+ 绱鏀跺叆
+ </summary>
+ </member>
<member name="P:LifePayment.Application.Contracts.TopStatisticsOutput.AccumulatedOrders">
<summary>
绱涓嬪崟
--
Gitblit v1.9.1