]> git.parisson.com Git - telemeta.git/commitdiff
Allowing html in collections' description
authoranas <anas.ghrab@gmail.com>
Wed, 21 Oct 2015 19:27:56 +0000 (21:27 +0200)
committeranas <anas.ghrab@gmail.com>
Wed, 21 Oct 2015 19:27:56 +0000 (21:27 +0200)
telemeta/templates/telemeta/collection_detail.html
telemeta/templates/telemeta/inc/children_list.html

index c9804fef0d917fc475dbf24a5f3eac360c5aef19..7184d11ef2150ae82a65e781c5f44e08be071820 100644 (file)
                 <dt>{% trans "Document status" %}</dt>
                 <dd>{{ collection.document_status }}</dd>
                 {% if collection.description %}
-                {% dl_field collection "description" %}
-                {% endif %}
-                {% dl_field collection "recording_context" %}
+               <dt>{% trans "Description" %}</dt>
+               <dd>{{ collection.description|html_line_break|safe }}</dd>
+               {% endif %}
+               {% dl_field collection "recording_context" %}
                 <dt>{% trans "Recording period" %}</dt>
                     <dd>{% if collection.recorded_from_year %}{{ collection.recorded_from_year }}{% endif %}{% if collection.recorded_from_year and collection.recorded_to_year %} - {% endif %}{% if  collection.recorded_to_year %}{{ collection.recorded_to_year}}{% endif %}</dd>
                 {% if '_E_' in collection.public_id %}
index d994d39512e16a7cc1cb8ec9651f250952fcd6c4..7cc392d503bd1a0be37b7c9bb4b622e2ba642169 100644 (file)
@@ -28,7 +28,7 @@
        <center><span class="glyphicon glyphicon-volume-up" style="font-size: 1.3em;"></span></center>
       {% endif %}
     </td>
-    <td>{% if child.descriptions %}{{ child.descriptions }}{% else %}{{ child.description }}{% endif %}</td>
+    <td>{% if child.descriptions %}{{ child.descriptions|safe }}{% else %}{{ child.description|safe }}{% endif %}</td>
     <td>{{ child.code }}</td>
 </tr>
 {% endif %}