feat(cms): add season dropdown/create and restore baelle ratio
Some checks failed
Code Analysis and Production Deploy / analyze (push) Failing after 2m39s
Code Analysis and Production Deploy / deploy-production (push) Has been skipped
Code Analysis and Production Deploy / deploy-test (push) Has been skipped

This commit is contained in:
Torsten Schulz (local)
2026-05-20 17:49:19 +02:00
parent 2d42ef3ecd
commit f2f76dec56
3 changed files with 221 additions and 13 deletions

View File

@@ -244,6 +244,9 @@
<th class="px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
Sätze
</th>
<th class="px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
Bälle
</th>
<th class="px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
Punkte
</th>
@@ -276,6 +279,9 @@
<td class="px-4 py-3 whitespace-nowrap text-sm text-gray-900">
{{ formatSaetze(row) }}
</td>
<td class="px-4 py-3 whitespace-nowrap text-sm text-gray-900">
{{ formatBaelle(row) }}
</td>
<td class="px-4 py-3 whitespace-nowrap text-sm text-gray-900">
{{ formatPunkte(row) }}
</td>
@@ -672,6 +678,13 @@ const formatSaetze = (row) => {
return `${won ?? 0}:${lost ?? 0}`
}
const formatBaelle = (row) => {
const won = row?.games_won
const lost = row?.games_lost
if (won == null && lost == null) return row?.games_relation || '-'
return `${won ?? 0}:${lost ?? 0}`
}
const formatPunkte = (row) => {
if (row?.points_won == null && row?.points_lost == null) return '-'
return `${row?.points_won ?? 0}:${row?.points_lost ?? 0}`