From ea7075f707bcc74a28379232fad381ed10e145ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jon=C3=A1=C5=A1=20Havelka?= Date: Mon, 2 Jan 2023 21:09:56 +0100 Subject: [PATCH] =?UTF-8?q?fix:=20=C5=99azen=C3=AD=20=C5=99e=C5=A1itel?= =?UTF-8?q?=C5=AF=20v=20odm=C4=9Bn=C3=A1ch=20podle=20p=C5=99=C3=ADjmen?= =?UTF-8?q?=C3=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- seminar/views/views_all.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/seminar/views/views_all.py b/seminar/views/views_all.py index 3f2cdf01..01c561eb 100644 --- a/seminar/views/views_all.py +++ b/seminar/views/views_all.py @@ -450,9 +450,9 @@ class OdmenyView(generic.TemplateView): frombody = body_resitelu(resitele=resitele, jen_verejne=False, do=from_deadline) tobody = body_resitelu(resitele=resitele, jen_verejne=False, do=to_deadline) outlist = [] - for (aid, tbody) in tobody.items(): - fbody = frombody.get(aid,0) - resitel = Resitel.objects.get(pk=aid) + for resitel in resitele: + fbody = frombody.get(resitel.id, 0) + tbody = tobody.get(resitel.id, 0) ftitul = resitel.get_titul(fbody) ttitul = resitel.get_titul(tbody) if ftitul != ttitul: