Browse Source

Podbarveni menu clanky

remotes/origin/cislopdf
Bc. Petr Pecha 9 years ago
parent
commit
a5f816240c
  1. 20
      mamweb/templates/flatpages/default.html
  2. 2
      seminar/templates/seminar/clanky/base.html
  3. 6
      seminar/templates/seminar/clanky/submenu.html

20
mamweb/templates/flatpages/default.html

@ -52,11 +52,11 @@
{% with "ulohy" as selected %} {% with "ulohy" as selected %}
{% include "seminar/zadani/submenu.html" %} {% include "seminar/zadani/submenu.html" %}
{% endwith %} {% endwith %}
{% elif "aktualni-cislo" in flatpage.url %} {% elif "/aktualni-cislo/" in flatpage.url %}
{% with "aktualni-cislo" as selected %} {% with "aktualni-cislo" as selected %}
{% include "seminar/zadani/submenu.html" %} {% include "seminar/zadani/submenu.html" %}
{% endwith %} {% endwith %}
{% elif "vysledkove-listiny" in flatpage.url %} {% elif "/vysledkove-listiny/" in flatpage.url %}
{% with "vysledkove-listiny" as selected %} {% with "vysledkove-listiny" as selected %}
{% include "seminar/zadani/submenu.html" %} {% include "seminar/zadani/submenu.html" %}
{% endwith %} {% endwith %}
@ -66,7 +66,21 @@
{% endif %} {% endif %}
{# clanky #} {# clanky #}
{% if "/clanky/" in flatpage.url %} {% if "/clanky/" in flatpage.url %}
{% include "seminar/clanky/submenu.html" %} {% if "/uvod/" in flatpage.url %}
{% with "uvod" as selected %}
{% include "seminar/clanky/submenu.html" %}
{% endwith %}
{% elif "/org/" in flatpage.url %}
{% with "org" as selected %}
{% include "seminar/clanky/submenu.html" %}
{% endwith %}
{% elif "/resitel/" in flatpage.url %}
{% with "resitel" as selected %}
{% include "seminar/clanky/submenu.html" %}
{% endwith %}
{% else %}
{% include "seminar/clanky/submenu.html" %}
{% endif %}
{% endif %} {% endif %}
{# archiv #} {# archiv #}
{% if "/archiv/" in flatpage.url %} {% if "/archiv/" in flatpage.url %}

2
seminar/templates/seminar/clanky/base.html

@ -1,5 +1,7 @@
{% extends "base.html" %} {% extends "base.html" %}
{% block menu_clanky %}selected{% endblock %}
{% block submenu %} {% block submenu %}
{% include "seminar/clanky/submenu.html" %} {% include "seminar/clanky/submenu.html" %}
{% endblock %} {% endblock %}

6
seminar/templates/seminar/clanky/submenu.html

@ -1,9 +1,9 @@
{% with "/clanky" as cesta %} {% with "/clanky" as cesta %}
<ul> <ul>
<li><a href="{{cesta}}/uvod/">Úvod</a> <li class="{% if selected == "uvod" %}selected{% endif %}"><a href="{{cesta}}/uvod/">Úvod</a>
<li><a href="{{cesta}}/org/">Organizátorské články</a> <li class="{% if selected == "org" %}selected{% endif %}"><a href="{{cesta}}/org/">Organizátorské články</a>
<li><a href="{{cesta}}/resitel/">Řešitelské články</a> <li class="{% if selected == "resitel" %}selected{% endif %}"><a href="{{cesta}}/resitel/">Řešitelské články</a>
</ul> </ul>
{% endwith %} {% endwith %}

Loading…
Cancel
Save