From e73be6cf40b50173753a65f6596eb582b1e072ea Mon Sep 17 00:00:00 2001 From: Cédric Bonhomme Date: Tue, 12 Nov 2013 22:52:04 +0100 Subject: Article searching with Whoosh OK. --- pyaggr3g470r/templates/search.html | 43 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 pyaggr3g470r/templates/search.html (limited to 'pyaggr3g470r/templates/search.html') diff --git a/pyaggr3g470r/templates/search.html b/pyaggr3g470r/templates/search.html new file mode 100644 index 00000000..93fe5062 --- /dev/null +++ b/pyaggr3g470r/templates/search.html @@ -0,0 +1,43 @@ + {% extends "layout.html" %} +{% block content %} +
+ {% if feeds|count == 0 %} +

No results.

+ {% else %} + {% for feed in feeds|sort(attribute="title") %} +
+
+

{{ feed.title }}

+ + + +
+
+ {% 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 %} +
+ {% endfor %} + {% if feed.articles|length % 3 != 0 %} +
+ {% for n in range(feed.articles|length-(feed.articles|length % 3), feed.articles|length) %} +
+ {% 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