acm-site/acmsite/templates/admin/users.html
Cara Salter 9f68d2fd47
Add ACM CSV export
Allows officers to easily bulk import members into ACM's web interface
2024-03-21 16:36:54 +11:00

46 lines
1.6 KiB
HTML

{% extends "admin/admin-layout.html" %}
{% block app_content %}
<h1>Member List</h1>
<a href="{{ url_for('admin.users_csv') }}" target="_blank">CSV for ACM</a>
<table class="table table-striped">
<thead>
<tr>
<th>Email</th>
<th>Name</th>
<th>Created</th>
<th>Last Login</th>
<th>Officer?</th>
<th>Options</th>
</tr>
</thead>
<tbody>
{% for u in u_list %}
<tr>
<td>{{ u.email }}</td>
<td>{{ u.first_name }} {{ u.last_name }}</td>
<td>{{ u.created }}</td>
<td>{{ u.last_login }}</td>
<td>{{ u.is_admin }}</td>
<td>
<div class="dropdown">
<a href="#" class="btn btn-primary dropdown-toggle"
data-bs-toggle="dropdown"><span
class="caret"></span></a>
<ul class="dropdown-menu">
{% if u.is_admin %}
<li class="dropdown-item">Demote Officer</li>
{% else %}
<li class="dropdown-item">Promote Officer</li>
{% endif %}
<li class="dropdown-item">View Event Checkins</li>
<li class="dropdown-item">Delete Member</li>
</ul>
</div>
</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endblock app_content %}