From f1d5beb5ab9eb0eea537d6f94282f3b49bad4314 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jon=C3=A1=C5=A1=20Havelka?= Date: Thu, 6 Oct 2022 11:17:56 +0200 Subject: [PATCH] =?UTF-8?q?U=C5=BE=20jsem=20se=20zase=20nechal=20nachytat?= =?UTF-8?q?=20na=20set=C5=99=C3=ADzen=C3=AD=20querysetu?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- seminar/models/tvorba.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/seminar/models/tvorba.py b/seminar/models/tvorba.py index 452a75e7..929fd9b8 100644 --- a/seminar/models/tvorba.py +++ b/seminar/models/tvorba.py @@ -333,7 +333,7 @@ class Cislo(SeminarModelBase): @property def posledni_deadline(self): - return self.deadline_v_cisle.all().last() + return self.deadline_v_cisle.all().order_by("deadline").last() class Deadline(SeminarModelBase): class Meta: