wip
This commit is contained in:
1 parent
3627a78989
commit
c143dcf727
2 files changed
+8
-8
No files matched your search
@@ -111,10 +111,9 @@ class LoadEvents
|
|||||||
}
|
}
|
||||||
})->pluck('match_id')->toArray();
|
})->pluck('match_id')->toArray();
|
||||||
|
|
||||||
|
|
||||||
$matches_played = StatistikoPlayer::query()
|
$matches_played = StatistikoPlayer::query()
|
||||||
->whereIn('match_id', $matches_season)
|
->whereIn('match_id', $matches_season)
|
||||||
->where('tm_player_id', '=', (int) $tm_player_id)
|
->where('tm_player_id', $tm_player_id)
|
||||||
->when($player_on_field, function ($query) use ($player_on_field) {
|
->when($player_on_field, function ($query) use ($player_on_field) {
|
||||||
// 'all' => 'All',
|
// 'all' => 'All',
|
||||||
// 'lineup' => 'Lineup',
|
// 'lineup' => 'Lineup',
|
||||||
@@ -133,7 +132,6 @@ class LoadEvents
|
|||||||
})
|
})
|
||||||
->pluck('match_id')->toArray();
|
->pluck('match_id')->toArray();
|
||||||
|
|
||||||
|
|
||||||
$description = ' with ' . StatistikoDetail::where('tm_player_id', (int) $tm_player_id)->value('name') . ' (' . \count($matches_played) . ')';
|
$description = ' with ' . StatistikoDetail::where('tm_player_id', (int) $tm_player_id)->value('name') . ' (' . \count($matches_played) . ')';
|
||||||
|
|
||||||
if (! $matches_played) {
|
if (! $matches_played) {
|
||||||
@@ -257,7 +255,6 @@ class LoadEvents
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
if ($team_position == 'home') {
|
if ($team_position == 'home') {
|
||||||
switch ($value['result_code']) {
|
switch ($value['result_code']) {
|
||||||
case '1':
|
case '1':
|
||||||
@@ -354,6 +351,9 @@ class LoadEvents
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
// dd($team_id, $value['home_id'], $value['away_id']);
|
||||||
|
|
||||||
switch ($value['result_code']) {
|
switch ($value['result_code']) {
|
||||||
case '1':
|
case '1':
|
||||||
if ($team_id == $value['home_id']) {
|
if ($team_id == $value['home_id']) {
|
||||||
@@ -532,6 +532,9 @@ class LoadEvents
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Log::debug($results);
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* LEAGUE AVERAGES
|
* LEAGUE AVERAGES
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ class StatsMedianAverage extends StatsOverviewWidget
|
|||||||
{
|
{
|
||||||
$data = LoadEvents::load($this->filters, false);
|
$data = LoadEvents::load($this->filters, false);
|
||||||
|
|
||||||
// Log::debug($this->filters, $data);
|
// Log::debug($data['datasets']);
|
||||||
|
|
||||||
$team_position = HelperTeamPosition::get($this->filters);
|
$team_position = HelperTeamPosition::get($this->filters);
|
||||||
|
|
||||||
@@ -43,9 +43,6 @@ class StatsMedianAverage extends StatsOverviewWidget
|
|||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
|
|
||||||
$arr_home = [];
|
|
||||||
$arr_away = [];
|
|
||||||
|
|
||||||
$statistic_type = HelperStatisticType::get($this->filters);
|
$statistic_type = HelperStatisticType::get($this->filters);
|
||||||
|
|
||||||
if (! isset($data['datasets'][0])) {
|
if (! isset($data['datasets'][0])) {
|
||||||
|
|||||||
Reference in new issue
Block a user