diff --git a/gestioncof/templates/home.html b/gestioncof/templates/home.html index 7616664f..9d32c40c 100644 --- a/gestioncof/templates/home.html +++ b/gestioncof/templates/home.html @@ -37,10 +37,13 @@ {% for tirage in open_tirages %} {% endfor %} @@ -49,7 +52,7 @@

Divers

{% endfor %} {% else %} diff --git a/gestioncof/views.py b/gestioncof/views.py index be0adb35..3b0a3104 100644 --- a/gestioncof/views.py +++ b/gestioncof/views.py @@ -14,6 +14,7 @@ from django.http import Http404, HttpResponse from django.contrib.auth.decorators import login_required from django.contrib.auth.views import login as django_login_view from django.contrib.auth.models import User +from django.utils import timezone import django.utils.six as six from gestioncof.models import Survey, SurveyAnswer, SurveyQuestion, \ @@ -40,7 +41,8 @@ def home(request): Survey.objects.filter(survey_open=True, old=False).all(), "open_events": Event.objects.filter(registration_open=True, old=False).all(), - "open_tirages": Tirage.objects.filter(active=True).all()} + "open_tirages": Tirage.objects.filter(active=True).all(), + "now": timezone.now()} return render(request, "home.html", data)