From 176e601ec283d3203658bd5e2f8f3a9116778a3d Mon Sep 17 00:00:00 2001 From: "Pavel \"LEdoian\" Turinsky" Date: Wed, 12 Oct 2022 03:09:12 +0200 Subject: [PATCH] =?UTF-8?q?Zal=C3=A1m=C3=A1n=C3=AD=20moc=20dlouh=C3=A9ho?= =?UTF-8?q?=20=C5=99=C3=A1dku?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- seminar/migrations/0104_hodnoceni_deadline_body.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/seminar/migrations/0104_hodnoceni_deadline_body.py b/seminar/migrations/0104_hodnoceni_deadline_body.py index 515a956d..1f34654e 100644 --- a/seminar/migrations/0104_hodnoceni_deadline_body.py +++ b/seminar/migrations/0104_hodnoceni_deadline_body.py @@ -68,7 +68,10 @@ def prirad_deadliny(apps, schema_editor): h.deadline_body = d h.save() - if h.cislo_body and (int(h.deadline_body.cislo.poradi[0]) + 2 < int(h.cislo_body.poradi[0]) or int(h.deadline_body.cislo.poradi[0]) > int(h.cislo_body.poradi[0])): + if h.cislo_body and ( + int(h.deadline_body.cislo.poradi[0]) + 2 < int(h.cislo_body.poradi[0]) + or int(h.deadline_body.cislo.poradi[0]) > int(h.cislo_body.poradi[0]) + ): log.error(f"Hodnocení {h.id} se špatně změnilo číslo z {h.cislo_body} na {h.deadline_body.cislo}")