From f54469e7afbb1eb6066b6ad7e774b946738899a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jon=C3=A1=C5=A1=20Havelka?= Date: Wed, 5 Oct 2022 21:14:27 +0200 Subject: [PATCH] =?UTF-8?q?Ostatn=C3=AD=20case?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- vysledkovky/utils.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/vysledkovky/utils.py b/vysledkovky/utils.py index ce988c50..92a62adc 100644 --- a/vysledkovky/utils.py +++ b/vysledkovky/utils.py @@ -294,6 +294,10 @@ class VysledkovkaCisla(Vysledkovka): prob = hodnoceni.problem nadproblem = prob.hlavni_problem.id + # Když nadproblém není "téma", pak je "Ostatní" + if nadproblem not in body_za_temata: + nadproblem = -1 + problem_slovnik = body_za_problemy[nadproblem][prob.id] nadproblem_slovnik = body_za_temata[nadproblem]