36 lines
1.4 KiB
HTML
36 lines
1.4 KiB
HTML
{% extends "layout/default.html" %}
|
|
{% block title %}{% trans %}group list{% endtrans %}{% endblock %}
|
|
{% block content %}
|
|
<table class="table table-hover align-middle">
|
|
<thead class="table-light">
|
|
<tr>
|
|
<th scope="col">{% trans %}group name{% endtrans %}</th>
|
|
<th scope="col">{% trans %}group description{% endtrans %}</th>
|
|
<th scope="col">{% trans %}member?{% endtrans %}</th>
|
|
<th scope="col">{% trans %}member count{% endtrans %}</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for group in groups|sort %}
|
|
{% if CURRENT_USER.entry_dn in group["member"] or USER_IS_ADMIN %}
|
|
<tr>
|
|
<th scope="row">
|
|
{% if USER_IS_ADMIN %}
|
|
<a href="{{ url_for("group_edit", ou=group["ou"]) }}">{{ group["ou"] }}</a>
|
|
{% else %}
|
|
{{ group["ou"] }}
|
|
{% endif %}
|
|
</th>
|
|
<td>{{ group["description"]|e }}</td>
|
|
{% if CURRENT_USER.entry_dn in group["member"] %}
|
|
<td>✅</td>
|
|
{% else %}
|
|
<td>❌</td>
|
|
{% endif %}
|
|
<td>{{ group["member"]|length }}</td>
|
|
</tr>
|
|
{% endif %}
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
{% endblock %}
|