From e6cb1067629968e65a7ed83f2dba9cbd047f1ab7 Mon Sep 17 00:00:00 2001 From: salam Date: Fri, 6 Mar 2026 06:49:13 +0100 Subject: [PATCH] wip --- app/Console/Commands/Grapper/Betsapi/Willhill.php | 2 +- app/Console/Commands/Grapper/TxOdds/Odds.php | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/app/Console/Commands/Grapper/Betsapi/Willhill.php b/app/Console/Commands/Grapper/Betsapi/Willhill.php index 77ff5542..f5a69725 100644 --- a/app/Console/Commands/Grapper/Betsapi/Willhill.php +++ b/app/Console/Commands/Grapper/Betsapi/Willhill.php @@ -58,7 +58,7 @@ class Willhill if ($debug) { $arr = [ - 'Mapper TxOdds to Bet365', + 'Mapper TXOdds to Bet365', 'TXdds ID : '.$event['txodds_id'], "Bet365 ID : $bet365_id", 'Willhill ID : '.$event['willhill_id'], diff --git a/app/Console/Commands/Grapper/TxOdds/Odds.php b/app/Console/Commands/Grapper/TxOdds/Odds.php index da5c17ed..91a9f7a6 100644 --- a/app/Console/Commands/Grapper/TxOdds/Odds.php +++ b/app/Console/Commands/Grapper/TxOdds/Odds.php @@ -92,7 +92,7 @@ class Odds *************************************************/ if ($debug) { - Notice::note('TxOdds MARKET Lastcall', 'p'); + Notice::note('TXOdds MARKET Lastcall', 'p'); } $market = '&ot='.Nuh::$options['txodds_market_id']; @@ -234,9 +234,10 @@ class Odds 'competition_group_id' => (int) $row->group['cgid'], ]; - $res = DB::transaction(function () use ($event_id, $event) { - return Event::updateOrCreate(['id' => (int) $event_id, $event]); + $res = DB::transaction(function () use ($row, $event) { + return Event::updateOrCreate(['id' => (int) $row['id']], $event); }, 5); + $event_id = $res->id; $group = [ 'competition_group_id' => (string) $row->group['cgid'], @@ -281,7 +282,7 @@ class Odds ElementGroup::updateOrCreate(['element_id' => (int) $row->ateam['id'], 'group_id' => (int) $row->group['id']], $element_group); if (Event::where('id', $event_id)->exists()) { - // inconsteny with CONSTRAINT when getting only market updates + // inconsistency with CONSTRAINT when getting only market updates foreach ($row->bookmaker as $book) {