mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2025-05-16 13:38:52 +00:00
27 lines
645 B
HTML
27 lines
645 B
HTML
{% load i18n %}
|
|
{% load utilities %}
|
|
{% load cache %}
|
|
{% spaceless %}
|
|
|
|
{% get_current_language as LANGUAGE_CODE %}
|
|
{# 10 second cache #}
|
|
{% cache 10 titleby LANGUAGE_CODE book.id %}
|
|
|
|
{% if book.authors.exists %}
|
|
{% blocktrans trimmed with path=book.local_path title=book|book_title %}
|
|
<a href="{{ path }}">{{ title }}
|
|
</a>
|
|
by
|
|
{% endblocktrans %} {% include 'snippets/authors.html' with book=book limit=3 %}
|
|
|
|
{% else %}
|
|
<a href="{{ book.local_path }}">{{ book|book_title }}</a>
|
|
{% endif %}
|
|
|
|
{% if book.series %}
|
|
({{book.series}}{%if book.series_number %}, #{{book.series_number}}{% endif %})
|
|
{% endif %}
|
|
|
|
|
|
{% endcache %}
|
|
{% endspaceless %}
|