فهرست منبع

service fee 统计

laowu 2 هفته پیش
والد
کامیت
770d5555a2

+ 1 - 1
app/Game/Services/AgentSystemService.php

@@ -82,7 +82,7 @@ class AgentSystemService
         //StoredProcedure::addPlatformData($UserID, 4, $TakeMoney);
 
         // 数据统计后台 -- 提现记录添加
-        (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $orderWithDraw->withdraw_fee);
+        (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $orderWithDraw->withdraw_fee, $orderWithDraw->ServiceFee);
         $RecordData = [
             'before_state' => $query->State,
             'after_state' => $withdraw_data['State'] ?? 0,

+ 1 - 1
app/Http/logic/admin/WithdrawalLogic.php

@@ -575,7 +575,7 @@ class WithdrawalLogic extends BaseLogicController
         StoredProcedure::addPlatformData($UserID, 4, $TakeMoney);
 
         // 数据统计后台 -- 提现记录添加
-        (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdrawOrder->withdraw_fee);
+        (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdrawOrder->withdraw_fee, $withdrawOrder->ServiceFee);
 
         $redis = Redis::connection();
         $redis->incr('draw_'.date('Ymd').$UserID);

+ 1 - 1
app/Http/logic/api/AiNewPayCashierLogic.php

@@ -204,7 +204,7 @@ class AiNewPayCashierLogic implements CashierInterFace
                     $ServiceFee = $query->ServiceFee;
                     RecordUserDataStatistics::updateOrAdd($UserID, $TakeMoney, 0, $ServiceFee);
 
-                    (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdraw_data['withdraw_fee'] ?? 0);
+                    (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdraw_data['withdraw_fee'] ?? 0, $ServiceFee);
 
                     $redis = Redis::connection();
                     $redis->incr('draw_' . date('Ymd') . $UserID);

+ 1 - 1
app/Http/logic/api/AiPayCashierLogic.php

@@ -294,7 +294,7 @@ class AiPayCashierLogic implements CashierInterFace
         RecordUserDataStatistics::updateOrAdd($UserID, $TakeMoney, 0, $serviceFee);
         $fee = DB::table('QPAccountsDB.dbo.OrderWithDraw')->where('OrderId', $OrderId)
             ->value('withdraw_fee');
-        (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $fee);
+        (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $fee, $serviceFee);
         $redis = Redis::connection();
         $redis->incr('draw_' . date('Ymd') . $UserID);
         PrivateMail::successMail($UserID, $OrderId, $TakeMoney);

+ 1 - 1
app/Http/logic/api/CoinPayCashierLogic.php

@@ -184,7 +184,7 @@ class CoinPayCashierLogic implements CashierInterFace
         RecordUserDataStatistics::updateOrAdd($UserID, $TakeMoney, 0, $serviceFee);
         $fee = DB::table('QPAccountsDB.dbo.OrderWithDraw')->where('OrderId', $OrderId)
             ->value('withdraw_fee');
-        (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $fee);
+        (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $fee, $serviceFee);
         $redis = Redis::connection();
         $redis->incr('draw_' . date('Ymd') . $UserID);
         PrivateMail::successMail($UserID, $OrderId, $TakeMoney);

+ 1 - 1
app/Http/logic/api/PagYeepPayCashierLogic.php

@@ -262,7 +262,7 @@ class PagYeepPayCashierLogic implements CashierInterFace
                     RecordUserDataStatistics::updateOrAdd($UserID, $TakeMoney, 0, $ServiceFee);
 
                     // 数据统计后台 -- 提现记录添加
-                    (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdraw_data['withdraw_fee'] ?? 0);
+                    (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdraw_data['withdraw_fee'] ?? 0, $ServiceFee);
 
                     $redis = Redis::connection();
                     $redis->incr('draw_' . date('Ymd') . $UserID);

+ 1 - 1
app/Http/logic/api/WDPayCashierLogic.php

@@ -240,7 +240,7 @@ class WDPayCashierLogic implements CashierInterFace
                     RecordUserDataStatistics::updateOrAdd($UserID, $TakeMoney, 0, $ServiceFee);
 
                     // 数据统计后台 -- 提现记录添加
-                    (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdraw_data['withdraw_fee'] ?? 0);
+                    (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdraw_data['withdraw_fee'] ?? 0, $ServiceFee);
 
                     $redis = Redis::connection();
                     $redis->incr('draw_' . date('Ymd') . $UserID);

+ 1 - 1
app/Http/logic/api/WiwiPayCashierLogic.php

@@ -223,7 +223,7 @@ class WiwiPayCashierLogic implements CashierInterFace
                     RecordUserDataStatistics::updateOrAdd($UserID, $TakeMoney, 0, $ServiceFee);
 
                     // 数据统计后台 -- 提现记录添加
-                    (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdraw_data['withdraw_fee']);
+                    (new RechargeWithDraw())->withDraw($UserID, $TakeMoney, $withdraw_data['withdraw_fee'] ?? 0, $ServiceFee);
 
                     $redis = Redis::connection();
                     $redis->incr('draw_' . date('Ymd') . $UserID);

+ 3 - 1
app/dao/Estatisticas/RechargeWithDraw.php

@@ -46,7 +46,7 @@ class RechargeWithDraw
 
     }
 
-    public function withDraw($UserID, $WithDraw, $Fee = 0)
+    public function withDraw($UserID, $WithDraw, $Fee = 0, $ServiceFee = 0)
     {
         try {
 
@@ -63,6 +63,7 @@ class RechargeWithDraw
                 ->update([
                     'total_cash' => DB::raw('total_cash+' . $WithDraw),
                     'total_cash_fee' => DB::raw('total_cash_fee+' . $Fee),
+                    'total_service_fee' => DB::raw('total_service_fee+' . $ServiceFee),
                 ]);
 
             DB::connection('mysql')->table('rummy_cash_statistics')
@@ -71,6 +72,7 @@ class RechargeWithDraw
                 ->update([
                     'total_cash' => DB::raw('total_cash+' . $WithDraw),
                     'total_cash_fee' => DB::raw('total_cash_fee+' . $Fee),
+                    'total_service_fee' => DB::raw('total_service_fee+' . $ServiceFee),
                 ]);
         } catch (\Exception $exception) {
             Log::info('【提现】数据统计后台信息添加失败' . $UserID . ' - ' . $WithDraw);