|
|
@ -43,18 +43,22 @@ Galerie {{galerie.nazev}} |
|
|
|
{% endif %} |
|
|
|
|
|
|
|
{% if podgalerie %} |
|
|
|
{% with 22 as max_delka_nazvu %} |
|
|
|
<div class="galerie_nahledy"> |
|
|
|
{% for galerie in podgalerie %} |
|
|
|
<a href="../{{galerie.pk}}" class="podgalerie_nahled"> |
|
|
|
<a href="../{{galerie.pk}}" |
|
|
|
{% if galerie.nazev|length > max_delka_nazvu %} |
|
|
|
title="{{ galerie.nazev }}" |
|
|
|
{% endif %} |
|
|
|
class="podgalerie_nahled"> |
|
|
|
{% if galerie.titulni_obrazek %} |
|
|
|
{% with galerie.titulni_obrazek.obrazek_maly as obrazek %} |
|
|
|
<img src="{{ obrazek.url }}" |
|
|
|
width="{% widthratio obrazek.width 167 obrazek.width %}" |
|
|
|
height="{% widthratio obrazek.width 167 obrazek.height %}" /> |
|
|
|
{% endwith %} |
|
|
|
{% with galerie.titulni_obrazek.obrazek_maly as obrazek %} |
|
|
|
<img src="{{ obrazek.url }}" |
|
|
|
/> |
|
|
|
{% endwith %} |
|
|
|
{% endif %} |
|
|
|
<div> |
|
|
|
{{ galerie }} |
|
|
|
<div class="nazev_galerie"> |
|
|
|
{{ galerie|truncatechars:max_delka_nazvu }} |
|
|
|
</div> |
|
|
|
</a> |
|
|
|
{% if user.is_staff and galerie.zobrazit > 0 %} |
|
|
@ -66,6 +70,7 @@ Galerie {{galerie.nazev}} |
|
|
|
{% endif %} |
|
|
|
{% endfor %} |
|
|
|
</div> |
|
|
|
{% endwith %} |
|
|
|
{% endif %} |
|
|
|
{% endif %} |
|
|
|
{% if user.is_staff and galerie.zobrazit > 0 %} |
|
|
@ -84,6 +89,9 @@ Galerie {{galerie.nazev}} |
|
|
|
{% endif %} |
|
|
|
href="./{{obrazek.pk}}#nahoru" class="galerie_nahled"><span class="vystredeno"></span><img |
|
|
|
src="{{obrazek.obrazek_maly.url}}" |
|
|
|
{% if obrazek.popis %} |
|
|
|
title="{{ obrazek.popis }}" |
|
|
|
{% endif %} |
|
|
|
width="{{ obrazek.obrazek_maly.width }}" |
|
|
|
height="{{ obrazek.obrazek_maly.height }}" /> |
|
|
|
</a> |
|
|
|