diff options
author | Alban Gruin | 2017-11-27 16:37:31 +0100 |
---|---|---|
committer | Alban Gruin | 2017-11-27 16:37:31 +0100 |
commit | fb6ea65e7d32dcf3d697e6c63985a018ada4d6b1 (patch) | |
tree | ca73e9ae756f1a06e857ac5caee2bcd2066705e9 /views.py | |
parent | 3b9eab819c603b1d3b2b59d79258ce6a05aa24b9 (diff) |
Ajout d’un gestionnaire pour Timetable récupérant automatiquement les
années
Réduit considérablement le nombre d’appels effectués dans l’interface
d’administration
Diffstat (limited to 'views.py')
-rw-r--r-- | views.py | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -31,7 +31,7 @@ def index(request): def mention_list(request, year_slug): year = get_object_or_404(Year, slug=year_slug) - timetables = Timetable.objects.order_by("name").filter(year=year).select_related("year") + timetables = Timetable.objects.order_by("name").filter(year=year) return render(request, "index.html", {"year": year, "elements": timetables}) |