X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/357027375ff8867f42ca34bcbfb5a78b5b185fc3..cafca91e28661f24abbcda91c733de7e77d16e86:/src/catalogue/templates/catalogue/book_detail.html diff --git a/src/catalogue/templates/catalogue/book_detail.html b/src/catalogue/templates/catalogue/book_detail.html index 7e8128fa7..d2bfda7e4 100644 --- a/src/catalogue/templates/catalogue/book_detail.html +++ b/src/catalogue/templates/catalogue/book_detail.html @@ -1,8 +1,9 @@ -{% extends "base.html" %} +{% extends "base/base.html" %} {% load i18n %} -{% load common_tags catalogue_tags %} -{% load ssify %} +{% load catalogue_tags %} {% load build_absolute_uri from fnp_common %} +{% load annoy_banner from annoy %} +{% load cache %} {% block titleextra %}{{ book.pretty_title }}{% endblock %} {% block ogimage %}{% if book.cover %}{{ book.cover.url|build_absolute_uri:request }}{% endif %}{% endblock %} @@ -11,26 +12,80 @@ {% block bodyid %}book-detail{% endblock %} + {% block body %} + {% include 'catalogue/book_wide.html' %} + + {% work_list book_children %} + + {% spaceless %} + {% if book.other_versions %} +
+

{% trans "Other versions" %}:

+ {% for rel in book.other_versions %} + {{ rel.mini_box }} + {% endfor %} +
+ {% endif %} + + {% annoy_banner 'book-page' %} + +
+

{% trans "See also" %}:

+ {% related_books book taken=book.other_versions|length %} +
+ {% endspaceless %} + + {% with book.related_themes as themes %} + {% if themes %} +

{% trans "Themes" %}

+ {% plain_list themes book=book %} + {% endif %} + {% endwith %} + + +

{% trans "Information about the work" %}

+ {% for author in book.authors %} +
+ + {% cache 86400 catalogue_tag_box author.pk %} + {% include 'catalogue/tag_box.html' with tag=author %} + {% endcache %} + +
+ {% endfor %} + -{% ssi_include 'catalogue_book_wide' pk=book.pk %} - -{% work_list book_children %} - -{% spaceless %} -{% if book.other_versions %} -
-

{% trans "Other versions" %}:

-{% for rel in book.other_versions %} - {% ssi_include 'catalogue_book_mini' pk=rel.pk %} -{% endfor %} -
-{% endif %} - -
-

{% trans "See also" %}:

-{% related_books book taken=book.other_versions|length %} -
-{% endspaceless %} + {% with extra_info=book.get_extra_info_json %} + {% for source_url in extra_info.source_urls %} +
+ {% trans "Source" %} {% trans "of the book" %} + {% trans "in" %} {% source_name source_url %} +
+ {% empty %} + {% if extra_info.source_url %} +
+ {% trans "Source" %} {% trans "of the book" %} + {% trans "in" %} {% source_name extra_info.source_url %} +
+ {% endif %} + {% endfor %} + {% if book|status:user != 'closed' %} +
{% trans "Source XML file" %}
+ {% endif %} + {% if extra_info.about and not hide_about %} +
+ {% trans "Book on" %} {% trans "Editor's Platform" %} +
+ {% endif %} + {% if book.wiki_link %} +
+ {% trans "Book description on Wikipedia" %} +
+ {% endif %} +
+ {% trans "Mix this book" %} +
+{% endwith %} {% endblock %}