From b1800b77d3a647bd4d93d931b410d9ba18bebfd5 Mon Sep 17 00:00:00 2001 From: Cédric Bonhomme Date: Tue, 5 Nov 2013 22:41:19 +0100 Subject: Updated template for favorites. --- pyaggr3g470r/templates/favorites.html | 50 +++++++++++++++++++---------------- 1 file changed, 27 insertions(+), 23 deletions(-) (limited to 'pyaggr3g470r/templates') diff --git a/pyaggr3g470r/templates/favorites.html b/pyaggr3g470r/templates/favorites.html index 46842382..e60ccd85 100644 --- a/pyaggr3g470r/templates/favorites.html +++ b/pyaggr3g470r/templates/favorites.html @@ -1,37 +1,41 @@ {% extends "layout.html" %} {% block content %}
- {% for feed in feeds %} -
-
-

{{ feed.title }}

- -
-
- {% for number in range(0, feed.articles|length-(feed.articles|length % 3), 3) %} + {% if feeds|count == 0 %} +

No favorites.

+ {% else %} + {% for feed in feeds %}
- {% for n in range(number, number+3) %} -
- {% if feed.articles[n].readed %}

{% else %}

{% endif %} - {{ feed.articles[n].title }}

- {% if feed.articles[n].readed %}

{% else %}{% endif %} -
{{ feed.articles[n].date }}
+
+

{{ feed.title }}

+
- {% endfor %}
- {% endfor %} - {% if feed.articles|length % 3 != 0 %} -
- {% for n in range(0, feed.articles|length % 3) %} + {% for number in range(0, feed.articles|length-(feed.articles|length % 3), 3) %} +
+ {% for n in range(number, number+3) %}
{% if feed.articles[n].readed %}

{% else %}

{% endif %} {{ feed.articles[n].title }}

{% if feed.articles[n].readed %}

{% else %}{% endif %}
{{ feed.articles[n].date }}
- {% endfor %} -
- {% endif %} - {% endfor %} + {% endfor %} +
+ {% endfor %} + {% if feed.articles|length % 3 != 0 %} +
+ {% for n in range(0, feed.articles|length % 3) %} +
+ {% if feed.articles[n].readed %}

{% else %}

{% endif %} + {{ feed.articles[n].title }}

+ {% if feed.articles[n].readed %}

{% else %}{% endif %} +
{{ feed.articles[n].date }}
+
+ {% endfor %} +
+ {% endif %} + {% endfor %} + {% endif %}
{% endblock %} \ No newline at end of file -- cgit