2026-10-03 16:43:00 +02:00
|
|
|
<?php
|
|
|
|
|
// Stellt sicher, dass die benötigten Variablen vorhanden sind
|
2026-10-03 17:09:57 +02:00
|
|
|
if (!isset($selectedRound) || !isset($roundsToShow)) {
|
2026-10-03 16:43:00 +02:00
|
|
|
echo "Fehler: Daten für die Rundenansicht nicht gefunden.";
|
|
|
|
|
exit;
|
|
|
|
|
}
|
2026-10-03 17:09:57 +02:00
|
|
|
|
|
|
|
|
$pageTitle = 'Rundenübersicht - ' . htmlspecialchars($selectedRound['name']);
|
|
|
|
|
require __DIR__ . '/partials/header.php';
|
2026-10-03 16:43:00 +02:00
|
|
|
?>
|
2026-10-03 17:09:57 +02:00
|
|
|
|
|
|
|
|
<h1>Tippübersicht bis: <?php echo htmlspecialchars($selectedRound['name']); ?></h1>
|
|
|
|
|
|
|
|
|
|
<?php foreach ($roundsToShow as $round): ?>
|
|
|
|
|
<h2><?php echo htmlspecialchars($round['name']); ?></h2>
|
|
|
|
|
<?php if (!empty($round['games'])): ?>
|
2026-10-03 16:43:00 +02:00
|
|
|
<table>
|
|
|
|
|
<thead>
|
|
|
|
|
<tr>
|
|
|
|
|
<th>Anpfiff</th>
|
|
|
|
|
<th>Heim</th>
|
|
|
|
|
<th>Gast</th>
|
|
|
|
|
<th>Ergebnis</th>
|
|
|
|
|
<th>Status</th>
|
|
|
|
|
</tr>
|
|
|
|
|
</thead>
|
|
|
|
|
<tbody>
|
2026-10-03 17:09:57 +02:00
|
|
|
<?php foreach ($round['games'] as $game): ?>
|
2026-10-03 16:43:00 +02:00
|
|
|
<tr>
|
|
|
|
|
<td><?php echo htmlspecialchars((new DateTime($game['kickoff']))->format('d.m.Y H:i')); ?></td>
|
|
|
|
|
<td><?php echo htmlspecialchars($game['team1']); ?></td>
|
|
|
|
|
<td><?php echo htmlspecialchars($game['team2']); ?></td>
|
|
|
|
|
<td><?php echo App\Models\Game::getResultString($game['score1'], $game['score2'], $game['kickoff']); ?></td>
|
|
|
|
|
<td><?php echo App\Models\Game::isLocked($game['kickoff']) ? 'Gesperrt' : 'Offen'; ?></td>
|
|
|
|
|
</tr>
|
|
|
|
|
<?php endforeach; ?>
|
|
|
|
|
</tbody>
|
|
|
|
|
</table>
|
|
|
|
|
<?php else: ?>
|
|
|
|
|
<p>Für diese Runde wurden keine Spiele gefunden.</p>
|
|
|
|
|
<?php endif; ?>
|
2026-10-03 17:09:57 +02:00
|
|
|
<?php endforeach; ?>
|
|
|
|
|
|
|
|
|
|
<p><a href="/">Zurück zur Startseite</a></p>
|
2026-10-03 16:43:00 +02:00
|
|
|
|
2026-10-03 17:09:57 +02:00
|
|
|
<?php require __DIR__ . '/partials/footer.php'; ?>
|