]> gitweb.fperrin.net Git - djsite.git/blobdiff - quotes/templates/quotes/display.html
Fix template for HTML bits
[djsite.git] / quotes / templates / quotes / display.html
index fcf5906dc5ec720ac4909ce7310143ac90422f93..a9ff5cfbf3e5c6bdf78fc57f110654a6c8d24a17 100644 (file)
@@ -1,7 +1,7 @@
 <div class="quote">
-  <p class="text">
-    {{ quote.text }}
-  </p>
+  <div class="text">
+    {{ quote.text|safe }}
+  </div>
 
   <div class="details">
     <p id="details_{{ quote.id}}_button">
          Hide details</a></p>
       <p class="author">
        — <span class="name">
-         <a href="{% url 'quotes:author' quote.work.author.id %}"
+         <a href="{{ quote.work.author.get_absolute_url }}"
             class="author_name">{{ quote.work.author.name }}</a>,
-         <a href="{% url 'quotes:work' quote.work.id %}"
+         <a href="{% quote.work.get_absolute_url }}"
             class="work_name">{{ quote.work.name }}</a>
        </span>
       </p>
-
-      <div class="quote_notes">
-       <p>{{ quote.notes|safe }}</p>
-      </div>
-
+      {% if quote.notes %}
+        <div class="quote_notes">
+         {{ quote.notes|safe }}
+        </div>
+      {% endif %}
       {% if not skip_work_notes %}
         {% include "quotes/work_notes.html" with work=quote.work %}
       {% endif %}
       {% if not skip_author_notes %}
         {% include "quotes/author_notes.html" with author=quote.work.author %}
       {% endif %}
-      
-
       {% if quote.tags.all %}
       <p class="tags">
        Tags:
        {% for tag in quote.tags.all %}
-         <a href="{% url 'quotes:tags' tag.id %}" class="tag_link"
+         <a href="{{ tag.get_absolute_url }}" class="tag_link"
            >{{ tag.tag }}</a
            >{% if not forloop.last %}, {% endif %}
         {% endfor %}
@@ -47,6 +45,6 @@
     </div> <!-- /hidden_details -->
   </div>   <!-- /details -->
   <p class="permalink">
-    <a href="{% url 'quotes:onequote' quote.id %}">Permalink</a>
+    <a href="{{ quote.get_absolute_url }}">Permalink</a>
   </p>
 </div>