blob: db56be253fce7c63a2b2986f652df881203fc097 (
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
|
{% extends "layout.html" %}
{% block content %}
<div class="container">
<h1>{{ _('Registered users') }}</h1>
<table id="table-users" class="table table-striped">
<thead>
<tr>
<th>#</th>
<th>{{ _('Nickname') }}</th>
<th>{{ _('Member since') }}</th>
<th>{{ _('Last seen') }}</th>
<th>{{ _('Actions') }}</th>
</tr>
</thead>
<tbody>
{% for user in users %}
<tr {% if not user.is_active %}class="table-warning"{% endif %} {% if user.is_public_profile %}class="table-info"{% endif %}>
<td>{{ loop.index }}</td>
<td>
{% if user.is_public_profile %}
<a href="{{ url_for("user.profile_public", nickname=user.nickname) }}">{{ user.nickname }}</a>
{% else %}
{{ user.nickname }}
{% endif %}
{% if user.id == current_user.id %} (It's you!){% endif %}
</td>
<td class="date">{{ user.date_created | datetime }}</td>
<td class="date">{{ user.last_seen | datetime }}</td>
<td>
<a href="{{ url_for("admin.user_form", user_id=user.id) }}"><i class="fa fa-pencil-square-o" aria-hidden="true" title="{{ _('Edit this user') }}"></i></a>
{% if user.id != current_user.id %}
<a href="{{ url_for("admin.toggle_user", user_id=user.id) }}">
{% if user.is_active %}<i class="fa fa-ban" title="{{ _("Disable this account") }}"></i>{% else %}<i class="fa fa-check-circle-o" aria-hidden="true" title="{{ _("Enable this account") }}"></i>{% endif %}</a>
<a href="{{ url_for("admin.delete_user", user_id=user.id) }}"><i class="fa fa-times" aria-hidden="true" title="{{ _('Delete this user') }}" onclick="return confirm('{{ _('You are going to delete this account.') }}');"></i></a>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
<a href="{{ url_for("admin.user_form") }}" class="btn btn-primary">{{ _('Add a new user') }}</a>
</div>
{% endblock %}
|