Clanky | pokud je PDF s cislem, odkazat na nej.
This commit is contained in:
parent
d06d0ff2ea
commit
98f2ad12a7
1 changed files with 14 additions and 9 deletions
|
@ -9,15 +9,20 @@
|
|||
</h1>
|
||||
|
||||
{% for clanek in object_list %}
|
||||
{% with clanek.cislo.rocnik.rocnik as rocnik %}
|
||||
{% ifchanged rocnik %}
|
||||
{% if not forloop.first %}</ul>{% endif %}
|
||||
<h2>{{ rocnik }}. ročník</h2>
|
||||
<ul>
|
||||
{% endifchanged %}
|
||||
<li>
|
||||
<a href="{{ clanek.verejne_url }}">{{ clanek.nazev }}</a>
|
||||
{% endwith %}
|
||||
{% with clanek.cislo.rocnik.rocnik as rocnik %}
|
||||
{% ifchanged rocnik %}
|
||||
{% if not forloop.first %}</ul>{% endif %}
|
||||
<h2>{{ rocnik }}. ročník</h2>
|
||||
<ul>
|
||||
{% endifchanged %}
|
||||
<li>
|
||||
{% if clanek.cislo.pdf %}
|
||||
<a href="{{ clanek.cislo.pdf.url }}">{{ clanek.nazev }}</a>
|
||||
{% else %}
|
||||
{{ clanek.nazev }} (vyšlo v čísle {{clanek.cislo}})
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endwith %}
|
||||
{% endfor %}
|
||||
</ul>
|
||||
|
||||
|
|
Loading…
Reference in a new issue