From c16fb1bb2431f40eb4b8e1af13c5254e2cf41d5a Mon Sep 17 00:00:00 2001 From: sunpengfei <i@angelzzz.com> Date: 星期二, 10 六月 2025 19:04:02 +0800 Subject: [PATCH] fix:退款金额比例计算修改 --- LifePayment/LifePayment.Application/LifePay/LifePayService.cs | 7 ++++++- 1 files changed, 6 insertions(+), 1 deletions(-) diff --git a/LifePayment/LifePayment.Application/LifePay/LifePayService.cs b/LifePayment/LifePayment.Application/LifePay/LifePayService.cs index d2967c1..5eec9f9 100644 --- a/LifePayment/LifePayment.Application/LifePay/LifePayService.cs +++ b/LifePayment/LifePayment.Application/LifePay/LifePayService.cs @@ -1447,6 +1447,7 @@ } order.ActualReceivedAmount = actualParValue; + order.PlatformDeductionAmount = Math.Round((order.ActualReceivedAmount ?? 0) * (order.PlatformRate ?? 0) / 100, 2); if (acoolyOrderNo.IsNotNullOrEmpty()) { @@ -1465,11 +1466,15 @@ order.LifePayOrderStatus = status; order.ACOOLYStatus = acoolyStatus; + if (order.LifePayOrderStatus == LifePayOrderStatusEnum.宸插畬鎴� || order.LifePayOrderStatus == LifePayOrderStatusEnum.宸查��娆�) { order.FinishTime = DateTime.Now; - order.PlatformDeductionAmount = Math.Round((order.ActualReceivedAmount ?? 0) * (order.PlatformRate ?? 0) / 100, 2); + } + + if (order.ACOOLYStatus == ACOOLYStatusEnum.宸查��娆� || order.ACOOLYStatus == ACOOLYStatusEnum.閮ㄥ垎鍏呭�兼垚鍔�) + { order.RefundPrice = Math.Round((1 - ((order.ActualReceivedAmount ?? 0) / (order.RechargeAmount ?? 0))) * (order.PayAmount ?? 0), 2); } -- Gitblit v1.9.1