From 2e7a604adf53608a65d5f04c79b28a521667ef75 Mon Sep 17 00:00:00 2001
From: zhengyuxuan <zhengyuxuan1995>
Date: 星期五, 21 三月 2025 16:26:47 +0800
Subject: [PATCH] fix:bug修复

---
 LifePayment/LifePayment.Application/LifePay/LifePayService.cs |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/LifePayment/LifePayment.Application/LifePay/LifePayService.cs b/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
index 2b08ff7..65a57b4 100644
--- a/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
+++ b/LifePayment/LifePayment.Application/LifePay/LifePayService.cs
@@ -382,8 +382,8 @@
             ChannlesRakeRate = channle.ChannlesRakeRate,
             ChannlesRakePrice = channlesRakePrice.HasValue ? 0 : Math.Round(channlesRakePrice.Value, 2),
             PremiumRate = order.PremiumRate,
-            PremiumPrice = Math.Round(order.PayAmount * order.PremiumRate, 2),
-            Profit = (order.PayAmount - order.PlatformDeductionAmount) * (1.00m - channle.ChannlesRakeRate / 100) - Math.Round(order.PayAmount * order.PremiumRate, 2)
+            PremiumPrice = Math.Round(order.PayAmount * (order.PremiumRate.HasValue ? order.PremiumRate.Value:0), 2),
+            Profit = (order.PayAmount - order.PlatformDeductionAmount) * (1.00m - channle.ChannlesRakeRate / 100) - Math.Round(order.PayAmount * (order.PremiumRate.HasValue ? order.PremiumRate.Value : 0), 2)
         };
 
         return result;
@@ -1230,7 +1230,7 @@
             order.FinishTime = DateTime.Now;
         }
 
-        if (order.LifePayOrderStatus == LifePayOrderStatusEnum.宸插け璐� && order.PayStatus != LifePayStatusEnum.宸查��娆�)
+        if (order.LifePayOrderStatus == LifePayOrderStatusEnum.宸插け璐� && order.LifePayRefundStatus != LifePayRefundStatusEnum.宸查��娆�)
         {
             order.LifePayRefundStatus = LifePayRefundStatusEnum.寰呴��娆�;
         }

--
Gitblit v1.9.1