Ken 4 days ago
parent
commit
d17cafffa2
1 changed files with 1 additions and 2 deletions
  1. 1 2
      app/Services/BackflowService.php

+ 1 - 2
app/Services/BackflowService.php

@@ -34,12 +34,11 @@ class BackflowService extends BaseService
         } else {
             $backflow = static::$MODEL::create($data);
         }
-        $restriction = Config::where('field', 'huishui_percentage')->first()->val;
+        $restriction = Config::where('field', 'huishui_restriction')->first()->val;
         $difference = bcadd($backflow->recharge_amount, $backflow->withdrawal_amount, 2);
         $difference = abs($difference);
         if ($difference >= $restriction) {
             $backflow->amount = bcmul($difference, $backflow->backflow_ratio, 2);
-            $backflow->amount = $difference;
         } else {
             $backflow->amount = 0;
         }