1
0
mirror of https://gitlab.com/animath/si/plateforme.git synced 2025-02-06 08:53:02 +00:00
plateforme-tfjm2/tfjm/context_processors.py
Emmy D'Anello ec2fa43e20
Add single tournament mode
Signed-off-by: Emmy D'Anello <emmy.danello@animath.fr>
2024-06-07 15:18:59 +02:00

11 lines
285 B
Python

from django.conf import settings
from participation.models import Tournament
def tfjm_context(request):
return {
'TFJM_APP': settings.TFJM_APP,
'SINGLE_TOURNAMENT': Tournament.objects.first() if Tournament.objects.exists() and settings.TFJM_APP else None,
}