This commit is contained in:
torsten 2026-10-27 12:59:45 +01:00
parent c707c09460
commit 9e6b96fb0d
17 changed files with 290 additions and 53 deletions

View file

@ -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,
];
}