X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/1615c0eec40aa73f7662469eaeb082ac14477d11..95045552540ca917d273954ebfa20b47a306bb93:/wolnelektury/templates/catalogue/tagged_object_list.html diff --git a/wolnelektury/templates/catalogue/tagged_object_list.html b/wolnelektury/templates/catalogue/tagged_object_list.html index fe8abc86c..5f7d69fe6 100644 --- a/wolnelektury/templates/catalogue/tagged_object_list.html +++ b/wolnelektury/templates/catalogue/tagged_object_list.html @@ -1,6 +1,6 @@ {% extends "base.html" %} {% load i18n %} -{% load catalogue_tags pagination_tags %} +{% load catalogue_tags pagination_tags switch_tag %} {% block title %}{% title_from_tags tags %} w WolneLektury.pl{% endblock %} @@ -21,10 +21,11 @@ {% with tags|last as last_tag %} {% if last_tag.has_description %}
- {{ last_tag.description|safe }} +
{{ last_tag.description|safe }}
+
{{ last_tag.description|safe|truncatewords_html:30 }}
-

{% trans "Hide description" %} ▲

+

{% endif %} {% if shelf_is_set %} @@ -54,22 +55,34 @@ {% endif %} {% if last_tag.gazeta_link %}

- {% ifequal last_tag.category "author" %} - {% trans "Read work's study of this author on Lektury.Gazeta.pl" %} - {% endifequal %} - {% ifequal last_tag.category "epoch" %} - {% trans "Read study of epoch" %} {{ last_tag }} {% trans "on Lektury.Gazeta.pl" %} - {% endifequal %} + {% switch last_tag.category %} + {% case "author" %} + {% trans "Read work's study of this author on Lektury.Gazeta.pl" %} + {% case "epoch" %} + {% blocktrans %}Read study of epoch {{ last_tag }} on Lektury.Gazeta.pl{% endblocktrans %} + {% case "kind" %} + {% blocktrans %}Read study of kind {{ last_tag }} on Lektury.Gazeta.pl{% endblocktrans %} + {% case "genre" %} + {% blocktrans %}Read study of genre {{ last_tag }} on Lektury.Gazeta.pl{% endblocktrans %} + {% else %} + {% trans "Read related study on Lektury.Gazeta.pl" %} + {% endswitch %}

{% endif %} {% if last_tag.wiki_link %}

- {% ifequal last_tag.category "author" %} - {% trans "Read article about this author on Wikipedia" %} - {% endifequal %} - {% ifequal last_tag.category "epoch" %} - {% trans "Read article about epoch" %} {{ last_tag }} {% trans "on Wikipedia" %} - {% endifequal %} + {% switch last_tag.category %} + {% case "author" %} + {% trans "Read article about this author on Wikipedia" %} + {% case "epoch" %} + {% blocktrans %}Read article about epoch {{ last_tag }} on Wikipedia{% endblocktrans %} + {% case "kind" %} + {% blocktrans %}Read article about kind {{ last_tag }} on Wikipedia{% endblocktrans %} + {% case "genre" %} + {% blocktrans %}Read article about genre {{ last_tag }} on Wikipedia{% endblocktrans %} + {% else %} + {% trans "Read related article on Wikipedia" %} + {% endswitch %}

{% endif %}