summaryrefslogtreecommitdiffstats
path: root/hyperkitty/templates/ajax
diff options
context:
space:
mode:
authorAurélien Bompard <aurelien@bompard.org>2013-05-23 15:45:22 +0200
committerAurélien Bompard <aurelien@bompard.org>2013-05-23 17:48:16 +0200
commitea032ba8b321fad5e896750eae508456676041c1 (patch)
tree026c8af089391ecddd9dcae5a05d5ee9e07ad3a0 /hyperkitty/templates/ajax
parente9e92bf1ac15421b9a29c366b9ef6bf2c1b94943 (diff)
downloadhyperkitty-ea032ba8b321fad5e896750eae508456676041c1.tar.gz
hyperkitty-ea032ba8b321fad5e896750eae508456676041c1.tar.xz
hyperkitty-ea032ba8b321fad5e896750eae508456676041c1.zip
Display the last viewed threads in the user profile
Diffstat (limited to 'hyperkitty/templates/ajax')
-rw-r--r--hyperkitty/templates/ajax/last_views.html40
1 files changed, 40 insertions, 0 deletions
diff --git a/hyperkitty/templates/ajax/last_views.html b/hyperkitty/templates/ajax/last_views.html
new file mode 100644
index 0000000..5455413
--- /dev/null
+++ b/hyperkitty/templates/ajax/last_views.html
@@ -0,0 +1,40 @@
+{% load url from future %}
+{% load i18n %}
+{% load hk_generic %}
+
+ {% if last_views %}
+ <table class="table table-striped table-bordered table-condensed">
+ <thead>
+ <tr>
+ <th></th>
+ <th>Subject</th>
+ <th>Original author</th>
+ <th>Start date</th>
+ <th>Last activity</th>
+ <th>Replies</th>
+ </tr>
+ </thead>
+ <tbody>
+ {% for lv in last_views %}
+ <tr>
+ <td>
+ {% if thread.unread %}
+ <i class="unread icon-eye-close" title="New comments"></i>
+ {% endif %}
+ </td>
+ <td><a href="{% url 'thread' mlist_fqdn=lv.list_address threadid=lv.threadid %}"
+ >{{ lv.thread.starting_email.subject }}</a></td>
+ <td>{{ lv.thread.starting_email.sender_name }}</td>
+ <td>{{ lv.thread.starting_email|viewer_date|date:"l, j F Y H:i:s" }}</td>
+ <td>{{ lv.thread|viewer_date|timesince }}</td>
+ <td>{{ lv.thread|length }}</td>
+ </tr>
+ {% endfor %}
+ </tbody>
+ </table>
+ {% include "paginator.html" with pager=last_views page_key="lvpage" %}
+ {% else %}
+ <p>Nothing read yet.</p>
+ {% endif %}
+
+{# vim: set noet: #}