Add url for delete blogpost button.
authorAditi <aditi.iitr@gmail.com>
Mon, 5 Aug 2013 12:01:08 +0000 (17:31 +0530)
committerAditi <aditi.iitr@gmail.com>
Mon, 5 Aug 2013 12:01:08 +0000 (17:31 +0530)
mediagoblin/templates/mediagoblin/blog/blog_admin_dashboard.html

index c45f0e30e8ddd6e7ca66f706554c4209e56ff1f4..eb32fd4155ae15ac428bbc9bead31d2f8693834b 100644 (file)
@@ -25,7 +25,7 @@
 {% block mediagoblin_content %}
 <h1> {{blog.title}}</h1>
 <p>
-    {{blog.description}}  
+    {{blog.description|safe}}  
 </p> 
 <p>
     {% set blogpost_create_url = request.urlgen('mediagoblin.media_types.blog.blogpost.create', 
             {% set blogpost_edit_url = request.urlgen('mediagoblin.media_types.blog.blogpost.edit', 
                                       blog_slug=blog.slug, user=request.user.username, 
                                       blog_post_slug=blog_post.slug) %}
-            <td><a class="button_action" href="{{ blogpost_edit_url }}">Edit</a>
-            <a class="button_action" >Delete</a>
+            {% set blogpost_delete_url = request.urlgen('mediagoblin.user_pages.media_confirm_delete',
+                                 user= blog_post.get_uploader.username,
+                                 media_id=blog_post.id) %}
+            <td>
+            <a class="button_action" href="{{ blogpost_edit_url }}">{% trans %}Edit{% endtrans %}</a>
+            <a class="button_action" href="{{ blogpost_delete_url }}">{% trans %}Delete{% endtrans %}</a>
             </td>
-            
         </tr>
         {% endfor %}
      </table>