wip
This commit is contained in:
1 parent
0a936bc84b
commit
274d653f95
5 files changed
+16
-7
No files matched your search
@@ -69,6 +69,7 @@ class AverageTeam
|
||||
|
||||
if ($team_position == 'home' && $team_id == $val->home_id) {
|
||||
ExpectationAverage::filter($result, 'team', 'gls', $val->gls_h, $val->gls_a);
|
||||
ExpectationAverage::filter($result, 'team', 'crn', $val->crn_h, $val->crn_a);
|
||||
ExpectationAverage::filter($result, 'team', 'fls', $val->fls_h, $val->fls_a);
|
||||
ExpectationAverage::filter($result, 'team', 'ofs', $val->ofs_h, $val->ofs_a);
|
||||
ExpectationAverage::filter($result, 'team', 'crd', $val->crd_h, $val->crd_a);
|
||||
@@ -76,6 +77,7 @@ class AverageTeam
|
||||
ExpectationAverage::filter($result, 'team', 'tsh', $val->tsh_h, $val->tsh_a);
|
||||
} elseif ($team_position == 'away' && $team_id == $val->away_id) {
|
||||
ExpectationAverage::filter($result, 'team', 'gls', $val->gls_a, $val->gls_h);
|
||||
ExpectationAverage::filter($result, 'team', 'crn', $val->crn_a, $val->crn_h);
|
||||
ExpectationAverage::filter($result, 'team', 'fls', $val->fls_a, $val->fls_h);
|
||||
ExpectationAverage::filter($result, 'team', 'ofs', $val->ofs_a, $val->ofs_h);
|
||||
ExpectationAverage::filter($result, 'team', 'crd', $val->crd_a, $val->crd_h);
|
||||
@@ -83,6 +85,7 @@ class AverageTeam
|
||||
ExpectationAverage::filter($result, 'team', 'tsh', $val->tsh_a, $val->tsh_h);
|
||||
} else {
|
||||
ExpectationAverage::filter($result, 'team', 'gls', $val->gls_a, $val->gls_h);
|
||||
ExpectationAverage::filter($result, 'team', 'crn', $val->crn_a, $val->crn_h);
|
||||
ExpectationAverage::filter($result, 'team', 'fls', $val->fls_a, $val->fls_h);
|
||||
ExpectationAverage::filter($result, 'team', 'ofs', $val->ofs_a, $val->ofs_h);
|
||||
ExpectationAverage::filter($result, 'team', 'crd', $val->crd_a, $val->crd_h);
|
||||
@@ -91,7 +94,7 @@ class AverageTeam
|
||||
}
|
||||
}
|
||||
|
||||
$bets = ['gls', 'fls', 'ofs', 'crd', 'snt', 'tsh'];
|
||||
$bets = ['gls', 'crn', 'fls', 'ofs', 'crd', 'snt', 'tsh'];
|
||||
if ($result) {
|
||||
foreach ($bets as $bet) {
|
||||
$expectations[$bet.'_team']['home'] = round(array_sum($result['team'][$bet]['home']) / \count($result['team'][$bet]['home']), 1);
|
||||
@@ -104,6 +107,7 @@ class AverageTeam
|
||||
}
|
||||
}
|
||||
$expectations['gls_team']['name'] = 'Goals';
|
||||
$expectations['crn_team']['name'] = 'Corner';
|
||||
$expectations['fls_team']['name'] = 'Fouls';
|
||||
$expectations['ofs_team']['name'] = 'Offsides';
|
||||
$expectations['crd_team']['name'] = 'Cards';
|
||||
|
||||
Reference in new issue
Block a user