|
|
@@ -53,7 +53,7 @@ class SettlementWinFail
|
|
|
|
|
|
try {
|
|
|
|
|
|
- $ComendNoticModel = $this->getComendNoticeModel($id);
|
|
|
+ $this->ComendNoticModel = $ComendNoticModel = $this->getComendNoticeModel($id);
|
|
|
if (!$ComendNoticModel) {
|
|
|
return $this->makeData(1, '没有要处理的数据,直接退出');
|
|
|
}
|
|
|
@@ -67,13 +67,11 @@ class SettlementWinFail
|
|
|
$allmatchs = DB::table('money_buy_match')->where(['game_code' => $ComendNoticModel->game_code, 'match_id' => $ComendNoticModel->match_id])->get();
|
|
|
if (count($allmatchs) == 0) {
|
|
|
$this->writeStatusEndOk($ComendNoticModel);
|
|
|
- DB::table("st_" . $ComendNoticModel->game_code . "_result")->where(['match_id' => $ComendNoticModel->match_id])->update(['status' => 2]);
|
|
|
- DB::table("st_" . $ComendNoticModel->game_code . "_competition")->where(['match_id' => $ComendNoticModel->match_id])->update(['status' => 2]);
|
|
|
+ $this->cgStatus();
|
|
|
DB::commit();
|
|
|
return $this->makeData(1, '本赛事无订单数据,退出');
|
|
|
}
|
|
|
|
|
|
-
|
|
|
$this->gameType = $ComendNoticModel->game_code;
|
|
|
$this->match_id = $ComendNoticModel->match_id;
|
|
|
|
|
|
@@ -84,7 +82,7 @@ class SettlementWinFail
|
|
|
$this->Settlement_simplex($this->gameType, $this->match_id);
|
|
|
$this->Settlement_str($this->gameType, $this->match_id);
|
|
|
|
|
|
-
|
|
|
+ $this->cgStatus();
|
|
|
$this->writeStatusEndOk($ComendNoticModel);
|
|
|
DB::commit();
|
|
|
return $this->makeData(1, 'success-all');
|
|
|
@@ -96,6 +94,11 @@ class SettlementWinFail
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ private function cgStatus()
|
|
|
+ {
|
|
|
+ DB::table("st_" . $this->ComendNoticModel->game_code . "_result")->where(['match_id' => $this->ComendNoticModel->match_id])->update(['status' => 2]);
|
|
|
+ DB::table("st_" . $this->ComendNoticModel->game_code . "_competition")->where(['match_id' => $this->ComendNoticModel->match_id])->update(['status' => 2]);
|
|
|
+ }
|
|
|
|
|
|
//只处理某个订单下面的某场比赛的输赢结果
|
|
|
public function ProcWinInfoByOneOrder($match_id, $order_id, $bet_type = 1)
|