1
0
mirror of https://gitlab.com/animath/si/plateforme.git synced 2025-05-01 18:51:33 +00:00

On n'affiche pas les paiements pour la finale sur la liste des paiements d'un tournoi régional

This commit is contained in:
Emmy D'Anello 2025-04-28 20:43:36 +02:00
parent 60f5236dee
commit 203fc3cd54
Signed by: ynerant
GPG Key ID: 3A75C55819C8CF85

View File

@ -672,7 +672,7 @@ class TournamentPaymentsView(VolunteerMixin, SingleTableMixin, DetailView):
if self.object.final:
payments = Payment.objects.filter(final=True)
else:
payments = Payment.objects.filter(registrations__team__participation__tournament=self.get_object())
payments = Payment.objects.filter(registrations__team__participation__tournament=self.get_object(), final=False)
return payments.annotate(team_id=F('registrations__team')).order_by('-valid', 'registrations__team__trigram') \
.distinct().all()