From 8d0808d25ea0434ae3f5113b1656126ee929264c Mon Sep 17 00:00:00 2001 From: Tom Teichler <tom.teichler@teckids.org> Date: Sun, 1 Sep 2019 21:12:19 +0200 Subject: [PATCH] Fix get_object. --- biscuit/apps/chronos/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/biscuit/apps/chronos/views.py b/biscuit/apps/chronos/views.py index 48f30747..25b63912 100644 --- a/biscuit/apps/chronos/views.py +++ b/biscuit/apps/chronos/views.py @@ -118,7 +118,7 @@ def lessons_day(request: HttpRequest, when: Optional[str] = None) -> HttpRespons def edit_substitution(request: HttpRequest, id_: int, week: int) -> HttpResponse: context = {} - lesson_period = get_object_or_404(LessonPeriod, id_) + lesson_period = get_object_or_404(LessonPeriod, pk=id_) lesson_substitution = LessonSubstitution.objects.filter(week=week, lesson_period=lesson_period).first() if lesson_substitution: -- GitLab