This commit is contained in:
salam committed 2026-10-04 15:25:03 +02:00
1 parent 9bcd4432c6
commit 6f92f9e1d5
1209 files changed
+220940

No files matched your search

@@ -0,0 +1,26 @@
<?php
namespace App\Actions;
use App\Models\SofaScoreRosa;
use App\Models\StatisticFixtures;
class LoadStatisticFixturesMatchOptions
{
public static function load($league_id = 0)
{
if (! $league_id) {
return [];
}
$team_map = SofaScoreRosa::pluck('ss_team_name', 'ss_team_id')->toArray();
$res = StatisticFixtures::where('league_id', $league_id)->get();
$arr = [];
foreach ($res as $val) {
$arr[$val->id] = $val->starttime->format('Y-m-d H:i').' - '.$team_map[$val->home_id].' vs '.$team_map[$val->away_id];
}
return $arr;
}
}