X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/73b6a1639ba8f9f5fc7615c136364fdba73e5bb2..94a4fcc7ab9e1713dc2defc8b35c875fc90f6fa5:/src/catalogue/templates/catalogue/book_short.html diff --git a/src/catalogue/templates/catalogue/book_short.html b/src/catalogue/templates/catalogue/book_short.html index 675e761c4..133ed0cd6 100644 --- a/src/catalogue/templates/catalogue/book_short.html +++ b/src/catalogue/templates/catalogue/book_short.html @@ -1,5 +1,7 @@ {% spaceless %} {% load i18n %} + {% load thumbnail %} + {% load cache %} {% load catalogue_tags %} {% load book_shelf_tags from social_tags %} {% load static %} @@ -9,16 +11,23 @@
- {% block book-box-pre %} - {% include "catalogue/snippets/like_button.html" %} - {% endblock %} - {% with book.tags_by_category as tags %}
{% block book-box-body-pre %} {% endblock %} +
+ {% if book.cover_clean %} + + Cover + + {% endif %} + {% block cover-area-extra %}{% endblock %} +
+ + {% get_current_language as LANGUAGE_CODE %} + {% cache 86400 book_box_head_tags book.pk LANGUAGE_CODE %}
{% for tag in tags.author %} @@ -36,15 +45,6 @@ {% endif %}
-
- {% if book.cover_thumb %} - - Cover - - {% endif %} - {% block cover-area-extra %}{% endblock %} -
-
{% trans "Epoch" %}:  @@ -70,12 +70,14 @@ {% endfor %} - {% if book.extra_info.location %} - - {% trans "Region" %}:  - {{ book.extra_info.location }} - - {% endif %} + {% with extra_info=book.get_extra_info_json %} + {% if extra_info.location %} + + {% trans "Region" %}:  + {{ extra_info.location }} + + {% endif %} + {% endwith %} {% if book.is_foreign %} @@ -94,13 +96,16 @@ {% endif %} {% endwith %}
+ {% endcache %}
{% book_shelf_tags book.pk %} - {% if book|status:user != 'closed' %} + {% cache 86400 book_box_tools book.pk book|status:request.user LANGUAGE_CODE %} + {% if book|status:request.user != 'closed' %}
  • {% if book.html_file %} +
    {% content_warning book %}
    {% trans "Read online" %} {% endif %} {% if book.print_on_demand %} @@ -109,56 +114,55 @@ {% endif %}
  • - {% trans "Download" %}:
    + {% trans "Download an ebook" %}:
    {% if book.pdf_file %} - PDF + PDF {% endif %} {% if book.epub_file %} - EPUB + EPUB {% endif %} {% if book.mobi_file %} - MOBI + MOBI + {% endif %} + {% if book.fb2_file %} + FB2 {% endif %} - {% if book.has_audio %} - MP3 + {% if book.txt_file %} + TXT {% endif %} - {% trans "more" %} - - {% if book.fb2_file %} - FB2 - {% endif %} - {% if book.txt_file %} - TXT - {% endif %} - {% download_audio book mp3=False %} -
    +
    + {% if book.has_mp3_file %} +
    + {% trans "Download audiobook" %}:
    + {% download_audio book %} +
    + {% endif %} +
    {% custom_pdf_link_li book %} - {% trans "less" %} -
{% else %} -

{% trans "For now this work is only available for our subscribers." %}

+ {% block preview-info %} +

+ {% trans "For now this work is only available for our subscribers." %} + Wspieraj Wolne Lektury +

+
{% content_warning book %}
+ {% endblock %} {% endif %} + {% endcache %} {% block book-box-extra-info %}{% endblock %} {% block box-append %}{% endblock %}
+ {% endwith %} + {% if book.abstract %} -
+
{{ book.abstract|safe }}
{% endif %} - {% endwith %} - - {% block right-column %} - {% if audiobooks %} -
- {% include 'catalogue/snippets/jplayer.html' %} -
- {% endif %} - {% endblock %}