vali 6 years ago
parent
commit
8f7cc5b959
2 changed files with 3 additions and 4 deletions
  1. 1 1
      app/Logic/UnSettmatchLogic.php
  2. 2 3
      datainf/logic/HttpServerOnlySet.php

+ 1 - 1
app/Logic/UnSettmatchLogic.php

@@ -277,7 +277,7 @@ class UnSettmatchLogic
     {
         $ret = (new SetinfoModel())->getInfo(1001);
         if (is_array($ret)) {
-            $val = floatval($ret->infocontent);
+            $val = floatval($ret['infocontent']);
             $this->fanshui = $val;
             return $val;
         }

+ 2 - 3
datainf/logic/HttpServerOnlySet.php

@@ -367,8 +367,9 @@ class HttpServerOnlySet
             }
             $returnMoney += $getReturnMoney['returnMoney'] * $v->bet_money;
         }
+        $returnMoney = floatPointDigit($returnMoney - $simplexData->money * $this->fanshui);
+        //$returnMoney = sprintf("%.2f", substr(sprintf("%.3f", $returnMoney), 0, -1));
 
-        $returnMoney = sprintf("%.2f", substr(sprintf("%.3f", $returnMoney), 0, -1));
         // 判断盈亏  1 赢  2 输  3 平
         $game_status = $returnMoney > $simplexData->money ? 1 : ($returnMoney == $simplexData->money ? 3 : 2);
         // 修改投注表状态及盈亏
@@ -476,8 +477,6 @@ class HttpServerOnlySet
         }
         $money = floatPointDigit($money_s - $simplexData->money * $this->fanshui);
 
-        print_r(['debug', $money_s, $money, $this->fanshui, $simplexData]);
-
         $this->PushSqlToArray(" update money_buy_str  set settle_status=2 , game_status=1 , settlement_time='$newTime' , gain_money=$money  where order_id = '$order_id'");
         $this->WriteOrAddSettlement($game_code, $match_id, $bet_type, $order_id, $account_identity, $money);
         $useraccident = $simplexData->account_identity;