feat(cms): add season dropdown/create and restore baelle ratio
This commit is contained in:
@@ -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}`
|
||||
|
||||
Reference in New Issue
Block a user