From 6c3152d3dae65b79203986179e20f371e6d01781 Mon Sep 17 00:00:00 2001 From: Cédric Bonhomme Date: Sat, 3 May 2014 11:10:15 +0200 Subject: Using datetime filter in all templates. --- pyaggr3g470r/templates/admin/user.html | 4 ++-- pyaggr3g470r/templates/article.html | 4 ++-- pyaggr3g470r/templates/favorites.html | 4 ++-- pyaggr3g470r/templates/feed.html | 2 +- pyaggr3g470r/templates/opml.xml | 6 +++--- pyaggr3g470r/templates/unread.html | 4 ++-- 6 files changed, 12 insertions(+), 12 deletions(-) (limited to 'pyaggr3g470r/templates') diff --git a/pyaggr3g470r/templates/admin/user.html b/pyaggr3g470r/templates/admin/user.html index fb60d8b1..92b04b23 100644 --- a/pyaggr3g470r/templates/admin/user.html +++ b/pyaggr3g470r/templates/admin/user.html @@ -9,8 +9,8 @@

Membership

-

Member since {{ user.date_created.strftime('%A, %d %B %Y') }}.

-

Last seen: {{ user.last_seen.strftime('%A, %d %B %Y at %H:%M:%S') }}.

+

Member since {{ user.date_created | datetime }}.

+

Last seen: {{ user.last_seen | datetime }}.

diff --git a/pyaggr3g470r/templates/article.html b/pyaggr3g470r/templates/article.html index 81d5d2e4..83e23b34 100644 --- a/pyaggr3g470r/templates/article.html +++ b/pyaggr3g470r/templates/article.html @@ -14,10 +14,10 @@ {% else %} {% endif %} -
{{ article.date }}
+
{{ article.date | datetime }}
- {{ article.content|safe }} + {{ article.content | safe }}
diff --git a/pyaggr3g470r/templates/favorites.html b/pyaggr3g470r/templates/favorites.html index b0357b41..9be16692 100644 --- a/pyaggr3g470r/templates/favorites.html +++ b/pyaggr3g470r/templates/favorites.html @@ -25,7 +25,7 @@ {% if feed.articles[n].readed %}

{% else %}

{% endif %} {{ feed.articles[n].title|safe }} {% if feed.articles[n].readed %}

{% else %}{% endif %} -
{{ feed.articles[n].date }}
+
{{ feed.articles[n].date | datetime }}
{% endfor %}
@@ -37,7 +37,7 @@ {% if feed.articles[n].readed %}

{% else %}

{% endif %} {{ feed.articles[n].title|safe }} {% if feed.articles[n].readed %}

{% else %}{% endif %} -
{{ feed.articles[n].date }}
+
{{ feed.articles[n].date | datetime }}
{% endfor %} diff --git a/pyaggr3g470r/templates/feed.html b/pyaggr3g470r/templates/feed.html index 98e965e4..1caa6d13 100644 --- a/pyaggr3g470r/templates/feed.html +++ b/pyaggr3g470r/templates/feed.html @@ -21,7 +21,7 @@
{% if feed.articles.all()|count != 0 %} {{ _('The last article was posted') }} {{ elapsed.days }} {{ _('day(s) ago.') }}
- {{ _('Daily average') }}: {{ average }}, {{ _('between the') }} {{ first_post_date.strftime('%Y-%m-%d') }} {{ _('and the') }} {{ end_post_date.strftime('%Y-%m-%d') }}. + {{ _('Daily average') }}: {{ average }}, {{ _('between the') }} {{ first_post_date | datetime }} {{ _('and the') }} {{ end_post_date | datetime }}. {% endif %}

diff --git a/pyaggr3g470r/templates/opml.xml b/pyaggr3g470r/templates/opml.xml index 8918bb88..07d2b3d9 100644 --- a/pyaggr3g470r/templates/opml.xml +++ b/pyaggr3g470r/templates/opml.xml @@ -1,10 +1,10 @@ - + Feeds of {{ user.firstname }} - {{ now.strftime('%A, %d %B %Y') }} - {{ now.strftime('%A, %d %B %Y') }} + {{ now | datetime }} + {{ now | datetime }} {{ user.firstname }} {{ user.lastname }} {{ user.email }} diff --git a/pyaggr3g470r/templates/unread.html b/pyaggr3g470r/templates/unread.html index 5194aaca..6c5c5d08 100644 --- a/pyaggr3g470r/templates/unread.html +++ b/pyaggr3g470r/templates/unread.html @@ -27,7 +27,7 @@ {% if feed.articles[n].readed %}

{% else %}

{% endif %} {{ feed.articles[n].title|safe }} {% if feed.articles[n].readed %}

{% else %}{% endif %} -
{{ feed.articles[n].date }}
+
{{ feed.articles[n].date | datetime }}
{% endfor %} @@ -39,7 +39,7 @@ {% if feed.articles[n].readed %}

{% else %}

{% endif %} {{ feed.articles[n].title|safe }} {% if feed.articles[n].readed %}

{% else %}{% endif %} -
{{ feed.articles[n].date }}
+
{{ feed.articles[n].date | datetime }}
{% endfor %} -- cgit