From b4c693a9ab3c64618028c127728105b42ad0a03d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jon=C3=A1=C5=A1=20Havelka?= Date: Mon, 5 Feb 2024 19:50:17 +0100 Subject: [PATCH] =?UTF-8?q?Uchycen=C3=AD=20=C5=99=C3=A1dku=20a=20sloupce?= =?UTF-8?q?=20v=20tabulce?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mamweb/static/css/mamweb.css | 29 +++++++++++++++++++ .../templates/odevzdavatko/tabulka.html | 6 ++-- 2 files changed, 33 insertions(+), 2 deletions(-) diff --git a/mamweb/static/css/mamweb.css b/mamweb/static/css/mamweb.css index 4b4a5e51..0d699d5c 100644 --- a/mamweb/static/css/mamweb.css +++ b/mamweb/static/css/mamweb.css @@ -1243,6 +1243,35 @@ div.gdpr { background: rgb(253, 237, 213); } +/*Přichycování prvního sloupce a řádku*/ +.dosla_reseni { + display: block; + max-height: 90vh; + max-width: 90vw; + overflow: auto; + margin-left: 5vw; +} + +.dosla_reseni thead tr { + position: sticky; + top: 0; + z-index: 1; +} + +.dosla_reseni tr:nth-child(even) td:first-child, .dosla_reseni thead tr, .dosla_reseni thead tr:first-child td:first-child { + background: rgb(253, 237, 213); +} + +.dosla_reseni tr:nth-child(odd) td:first-child { + background: #fffbf6; +} + +.dosla_reseni tr td:first-child { + position: sticky; + left: 0; +} +/* */ + .odevzdana_reseni tr th, .odevzdana_reseni tr td { border: 1px solid black; diff --git a/odevzdavatko/templates/odevzdavatko/tabulka.html b/odevzdavatko/templates/odevzdavatko/tabulka.html index 7cd317e5..7ee90ea9 100644 --- a/odevzdavatko/templates/odevzdavatko/tabulka.html +++ b/odevzdavatko/templates/odevzdavatko/tabulka.html @@ -21,8 +21,8 @@ Do data (včetně): {{ filtr.reseni_do }} -
+ {# Prázdná buňka v levém horním rohu #} {% for p in problemy %} @@ -32,6 +32,8 @@ Do data (včetně): {{ filtr.reseni_do }} {% endfor %} + + {% for resitel,hodnoty in radky%} {% endfor %} +
@@ -52,8 +54,8 @@ Do data (včetně): {{ filtr.reseni_do }} {% endfor %}
-
{% endblock %}