NDOJ/templates/notification/list.html

50 lines
1.3 KiB
HTML
Raw Normal View History

2020-07-03 02:50:31 +00:00
{% extends "base.html" %}
{% block body %}
2023-01-27 23:11:10 +00:00
{% if not has_notifications %}
2020-07-03 02:50:31 +00:00
2023-01-27 23:11:10 +00:00
<h2 style="text-align: center;">{{ _('You have no notifications') }}</h2>
2020-07-03 02:50:31 +00:00
2023-01-27 23:11:10 +00:00
{% else %}
2020-07-03 02:50:31 +00:00
<table class="table">
2023-01-27 23:11:10 +00:00
<tr>
2020-07-03 02:50:31 +00:00
<th>{{ _('User') }}</th>
<th>{{ _('Activity') }}</th>
2020-10-20 03:54:13 +00:00
<th>{{ _('Link') }}</th>
2020-07-03 02:50:31 +00:00
<th>{{ _('Time') }}</th>
2023-01-27 23:11:10 +00:00
</tr>
{% for notification in notifications %}
<tr class="{{ 'highlight' if not notification.seen }}">
<td>
2020-10-20 03:54:13 +00:00
{% if notification.comment %}
2023-01-27 23:11:10 +00:00
{{ link_user(notification.comment.author) }}
2020-10-20 03:54:13 +00:00
{% else %}
2023-01-27 23:11:10 +00:00
{{ link_user(notification.author) }}
2020-10-20 03:54:13 +00:00
{% endif %}
2023-01-27 23:11:10 +00:00
</td>
<td>
2020-07-03 02:50:31 +00:00
{{ notification.category }}
2023-01-27 23:11:10 +00:00
</td>
<td>
2020-10-20 03:54:13 +00:00
{% if notification.comment %}
<a href="{{ notification.comment.link }}#comment-{{ notification.comment.id }}">{{ notification.comment.page_title }}</a>
2020-10-20 03:54:13 +00:00
{% else %}
2023-01-27 23:11:10 +00:00
{% autoescape off %}
{{notification.html_link}}
{% endautoescape %}
2020-10-20 03:54:13 +00:00
{% endif %}
2023-01-27 23:11:10 +00:00
</td>
<td>
2020-07-03 02:50:31 +00:00
{{ relative_time(notification.time) }}
2023-01-27 23:11:10 +00:00
</td>
</tr>
{% endfor %}
2020-07-03 02:50:31 +00:00
</table>
2023-01-27 23:11:10 +00:00
{% endif %}
2020-07-03 02:50:31 +00:00
{% endblock %}
2023-01-27 23:11:10 +00:00
<!--
2020-07-03 02:50:31 +00:00
-->