From af07925de6fe2c1153972b6e208582425ca9a20d Mon Sep 17 00:00:00 2001 From: Aditi Mittal Date: Thu, 5 Sep 2013 21:20:29 +0530 Subject: [PATCH] Created a template for viewing all blogs by a user. --- .../mediagoblin/blog/list_of_blogs.html | 64 +++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 mediagoblin/media_types/blog/templates/mediagoblin/blog/list_of_blogs.html diff --git a/mediagoblin/media_types/blog/templates/mediagoblin/blog/list_of_blogs.html b/mediagoblin/media_types/blog/templates/mediagoblin/blog/list_of_blogs.html new file mode 100644 index 00000000..a362c7ac --- /dev/null +++ b/mediagoblin/media_types/blog/templates/mediagoblin/blog/list_of_blogs.html @@ -0,0 +1,64 @@ +{# +# GNU MediaGoblin -- federated, autonomous media hosting +# Copyright (C) 2011, 2012 MediaGoblin contributors. See AUTHORS. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +#} + +{% extends "mediagoblin/base.html" %} + + +{% block mediagoblin_head%} + +{% endblock %} + +{% block mediagoblin_content %} + + {% for blog in blogs %} + {% set my_blog_url = request.urlgen('mediagoblin.media_types.blog.blog-dashboard', + blog_slug=blog.slug, user=request.user.username) %} + {% set others_blog_url = request.urlgen('mediagoblin.media_types.blog.blog_post_listing', + blog_slug=blog.slug, user=url_user) %} + {% if request.user.username == url_user%} + {{ blog.title }} + {% else %} + {{ blog.title }} + {% endif %} +
+ {% endfor %} +
+{% endblock mediagoblin_content %} + + + + + + + + + + + + + + + + + + + + + -- 2.25.1