1
0
mirror of https://gitlab.com/animath/si/plateforme.git synced 2024-12-25 07:02:22 +00:00

Force pool and passage tables to have chronological orders

This commit is contained in:
Yohann D'ANELLO 2021-04-15 23:03:51 +02:00
parent 9797268736
commit ffaa6e8116
Signed by: ynerant
GPG Key ID: 3A75C55819C8CF85

View File

@ -534,7 +534,7 @@ class TournamentDetailView(DetailView):
def get_context_data(self, **kwargs):
context = super().get_context_data(**kwargs)
context["teams"] = ParticipationTable(self.object.participations.all())
context["pools"] = PoolTable(self.object.pools.all())
context["pools"] = PoolTable(self.object.pools.order_by('id').all())
notes = dict()
for participation in self.object.participations.all():
@ -616,7 +616,7 @@ class PoolDetailView(LoginRequiredMixin, DetailView):
def get_context_data(self, **kwargs):
context = super().get_context_data(**kwargs)
context["passages"] = PassageTable(self.object.passages.all())
context["passages"] = PassageTable(self.object.passages.order_by('id').all())
if self.object.results_available or self.request.user.registration.is_volunteer:
# Hide notes before the end of the turn