Fix a template bug.

This commit is contained in:
Alexis Metaireau 2011-02-17 19:03:23 +00:00
commit 8171e1753c

View file

@ -3,13 +3,13 @@
{% block content %}
{% if articles %}
{% for article in articles_page.object_list %}
{# First item #}
{% if loop.first and not articles_page.has_previous() %}
<aside id="featured" class="body"><article>
<h1 class="entry-title"><a href="{{ SITEURL }}/{{ article.url
}}">{{ article.title }}</a></h1>
{% include 'article_infos.html' %}
{{ article.content }}
{% include 'comments.html' %}
<aside id="featured" class="body">
<article>
<h1 class="entry-title"><a href="{{ SITEURL }}/{{ article.url }}">{{ article.title }}</a></h1>
{% include 'article_infos.html' %}{{ article.content }}{% include 'comments.html' %}
</article>
{% if loop.length == 1 %}
{% include 'pagination.html' %}
@ -21,6 +21,7 @@
<hr />
<ol id="posts-list" class="hfeed">
{% endif %}
{# other items #}
{% else %}
{% if loop.first and articles_page.has_previous %}
<section id="content" class="body">
@ -39,12 +40,13 @@
</div><!-- /.entry-content -->
</article></li>
{% endif %}
{% if loop.last and (articles_page.has_previous() or not articles_page.has_previous() and loop.length > 1) %}
{% if loop.last and (articles_page.has_previous()
or not articles_page.has_previous() and loop.length > 1) %}
{% include 'pagination.html' %}
{% endif %}
{% endfor %}
{% if loop.length > 1 or articles_page.has_previous() %}
</ol><!-- /#posts-list -->
{% if loop.length > 1 %}
</section><!-- /#content -->
{% endif %}
{% else %}