...
This commit is contained in:
parent
c707c09460
commit
9e6b96fb0d
17 changed files with 290 additions and 53 deletions
|
|
@ -152,13 +152,20 @@ class Round {
|
|||
}
|
||||
|
||||
$missing = Tipp::getMissing((int)$round['id'], [(int)$userId]);
|
||||
$user = User::findById((int)$userId);
|
||||
|
||||
return [
|
||||
'round_id' => (int)$round['id'],
|
||||
'name' => (string)$round['name'],
|
||||
'lock_time' => $lockTime,
|
||||
'remaining' => self::formatRemainingTime($secondsLeft),
|
||||
'missing_tipps' => in_array((int)$userId, $missing['tipps'], true),
|
||||
'missing_joker' => in_array((int)$userId, $missing['joker'], true),
|
||||
'missing_payment' => $user
|
||||
? trim((string)$user['iban']) === '' && trim((string)$user['paypal']) === ''
|
||||
: false,
|
||||
'missing_email' => $user ? trim((string)$user['email']) === '' : false,
|
||||
'missing_mobile' => $user ? trim((string)$user['mobile']) === '' : false,
|
||||
];
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue