book mini box: cache instead of ssi
[wolnelektury.git] / src / catalogue / templates / catalogue / book_mini_box.html
index d77f910..b74d651 100755 (executable)
@@ -1,22 +1,24 @@
 {% spaceless %}
-<div class="book-mini-box">
-    <div class="book-mini-box-inner">
-    {% if with_link %}
-    <a href="{{ book.get_absolute_url }}">
-    {% endif %}
-        {% if book.cover_thumb %}
-            <img src="{{ book.cover_thumb.url }}" alt="{{ author }} – {{ book.title }}" class="cover" />
+  {% with book.author_unicode as author %}
+    <div class="book-mini-box">
+      <div class="book-mini-box-inner">
+        {% if not no_link %}
+          <a href="{{ book.get_absolute_url }}">
         {% endif %}
-        {% if show_lang %}
+          {% if book.cover_thumb %}
+            <img src="{{ book.cover_thumb.url }}" alt="{{ author }} – {{ book.title }}" class="cover" />
+          {% endif %}
+          {% if book.is_foreign %}
             <span class="language" title="{{ book.language_name }}">{{ book.language_code }}</span>
-        {% endif %}
-        <div class="desc">
+          {% endif %}
+          <div class="desc">
             <span class="mono author">{{ author }}</span>
             <span class="title">{{ book.title }}</span>
-        </div>
-    {% if with_link %}
-    </a>
-    {% endif %}
+          </div>
+        {% if not no_link %}
+          </a>
+        {% endif %}
+      </div>
     </div>
-</div>
+  {% endwith %}
 {% endspaceless %}
\ No newline at end of file