Fix bold lines in tfjm.org export

Signed-off-by: Emmy D'Anello <emmy.danello@animath.fr>
This commit is contained in:
Emmy D'Anello 2024-05-19 20:55:47 +02:00
parent 7a0341e7cf
commit f687deed14
Signed by: ynerant
GPG Key ID: 3A75C55819C8CF85
1 changed files with 3 additions and 2 deletions

View File

@ -62,8 +62,9 @@ class Command(BaseCommand):
self.w("<tbody>")
for i, (participation, note) in enumerate(notes):
self.w("<tr>")
if i < (2 if len(notes) >= 7 else 1):
self.w(f"\t<th>{participation.team.name} ({participation.team.trigram})</td>")
bold = (not tournament.final and participation.final) or (tournament.final and i < 2)
if bold:
self.w(f"\t<th>{participation.team.name} ({participation.team.trigram})</th>")
else:
self.w(f"\t<td>{participation.team.name} ({participation.team.trigram})</td>")
for pool in tournament.pools.filter(participations=participation).all():