You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
58 lines
1.7 KiB
58 lines
1.7 KiB
{% extends "base.html" %}
|
|
|
|
{% block title %}Users - Plutus{% endblock %}
|
|
|
|
{% block content %}
|
|
<div class="level">
|
|
<div class="level-left">
|
|
<h1 class="title">Users</h1>
|
|
</div>
|
|
<div class="level-right">
|
|
<a class="button is-primary" href="{{ url_for('auth.add_user') }}">
|
|
<span class="icon">
|
|
<i class="fas fa-plus"></i>
|
|
</span>
|
|
<span>Add User</span>
|
|
</a>
|
|
</div>
|
|
</div>
|
|
|
|
{% if users %}
|
|
<div class="table-container">
|
|
<table class="table is-fullwidth is-striped is-hoverable">
|
|
<thead>
|
|
<tr>
|
|
<th>ID</th>
|
|
<th>Username</th>
|
|
<th>Full Name</th>
|
|
<th>Email</th>
|
|
<th>Status</th>
|
|
<th>Created</th>
|
|
<th>Permissions</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for user in users %}
|
|
<tr>
|
|
<td>{{ user.id }}</td>
|
|
<td>{{ user.Username }}</td>
|
|
<td>{{ user.FullName }}</td>
|
|
<td>{{ user.Email }}</td>
|
|
<td>
|
|
<span class="tag is-{{ 'success' if user.Enabled else 'danger' }}">
|
|
{{ 'Active' if user.Enabled else 'Disabled' }}
|
|
</span>
|
|
</td>
|
|
<td>{{ user.Created.strftime('%Y-%m-%d %H:%M') }}</td>
|
|
<td>{{ user.Permissions or '-' }}</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
{% else %}
|
|
<div class="notification is-info">
|
|
<p>No users found. <a href="{{ url_for('auth.add_user') }}">Add the first user</a>.</p>
|
|
</div>
|
|
{% endif %}
|
|
{% endblock %}
|