summaryrefslogtreecommitdiffstats
path: root/hyperkitty/templates/ajax/last_views.html
blob: 0a6d97affc16dda6f62e8165d59036cd20b41f20 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
{% 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>List</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>{{ lv.list_address }}</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|get_date|date:"l, j F Y H:i:s" }}</td>
                    <td>{{ lv.thread|get_date|timesince }}</td>
                    <td>
                        {{ lv.thread|length }}
                        {% if thread.unread %}
                        / {{ thread.unread }} new
                        {% endif %}
                    </td>
                </tr>
            {% endfor %}
            </tbody>
        </table>
        {% include "paginator.html" with pager=last_views page_key="lvpage" %}
    {% else %}
        <p>Nothing read yet.</p>
    {% endif %}