From acc67ef6a45e19693b52d7ac2f6acfcf39588e3e Mon Sep 17 00:00:00 2001 From: salam Date: Thu, 30 Apr 2026 09:11:48 +0200 Subject: [PATCH] wip --- app/Actions/Statistics/LoadEvents.php | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/app/Actions/Statistics/LoadEvents.php b/app/Actions/Statistics/LoadEvents.php index f84af46a..de506030 100644 --- a/app/Actions/Statistics/LoadEvents.php +++ b/app/Actions/Statistics/LoadEvents.php @@ -48,10 +48,15 @@ class LoadEvents $datasets = []; $labels = []; + $statistic_type = $filter['statistic_type']; + if ($statistic_type == 'none') { + $statistic_type = 'gls'; + } + foreach ($res as $value) { $labels[] = $value['starttime']->format('d. M.y'); - dd($filter); + // dd($filter); // $tmp['exp_handicap'] = (float) $value['exp_handicap']; // $tmp['exp_total'] = (float) $value['exp_total']; @@ -60,7 +65,7 @@ class LoadEvents if ($team_position == 'home') { - switch ($filter['statistic_type']) { + switch ($statistic_type) { case 'gls': $val = (int) $value['gls_h']; break; @@ -85,7 +90,7 @@ class LoadEvents } } elseif ($team_position == 'away') { - switch ($filter['statistic_type']) { + switch ($statistic_type) { case 'gls': $val = (int) $value['gls_a']; break;