82 lines
3.6 KiB
Django/Jinja
82 lines
3.6 KiB
Django/Jinja
{% extends 'realm/realm_detailed.jinja2' %}
|
|
{% import 'macros/form_macros.jinja2' as mform %}
|
|
|
|
{% block detail_content %}
|
|
<h2>Nutzer löschen</h2>
|
|
{% if blocked_users %}
|
|
<div class="alert alert-warning">
|
|
<h3>Admin User festgestellt</h3>
|
|
<p>Die folgenden Nutzer können nicht gelöscht werden, da Sie noch Mitglieder von ein oder mehreren Admin
|
|
Gruppen sind. Bitte tragen Sie diese vorher aus den Admin Gruppen.</p>
|
|
<ul>
|
|
{% for blocked_user in blocked_users %}
|
|
<li>{{ blocked_user.username }}</li>
|
|
{% endfor %}
|
|
</ul>
|
|
</div>
|
|
{% endif %}
|
|
<div class="form-group w-25 float-right">
|
|
<input type="text"
|
|
class="form-control"
|
|
placeholder="Personen Suche"
|
|
id="data-table-search-input">
|
|
<label for="data-table-search-input">Suche</label>
|
|
</div>
|
|
<form action="{{ url('realm-multiple-user-delete', args=[realm.id]) }}" method="post">
|
|
<input type="hidden" name="csrfmiddlewaretoken" value="{{ csrf_token }}">
|
|
<table class="table table-hover table-striped table-inverse table-bordered data-table">
|
|
<thead>
|
|
<tr>
|
|
<th scope="col" class="text-center"></th>
|
|
<th scope="col">Nutzername</th>
|
|
<th scope="col">E-Mail</th>
|
|
<th scope="col">Vorname</th>
|
|
<th scope="col">Nachname</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for user in deletable_users %}
|
|
<tr>
|
|
<td class="text-center">
|
|
<input type="checkbox"
|
|
class="table-checkbox-control-input delete-checkbox"
|
|
id="user_{{ loop.index }}"
|
|
value="{{ user.username }}"
|
|
name="ldap_users"
|
|
checked
|
|
disabled
|
|
><label class="table-checkbox-control-label" for="user_{{ loop.index }}"></label>
|
|
</td>
|
|
<td>{{ user.username }}</td>
|
|
<td>{{ user.email }}</td>
|
|
<td>{{ user.first_name }}</td>
|
|
<td>{{ user.last_name }}</td>
|
|
</tr>
|
|
<input type="checkbox" value="{{ user.username }}" name="ldap_users" checked hidden>
|
|
{% endfor %}
|
|
{% for user in blocked_users %}
|
|
<tr>
|
|
<td class="text-center">
|
|
<input type="checkbox"
|
|
class="table-checkbox-control-input delete-checkbox"
|
|
id="user_{{ loop.index }}"
|
|
value="{{ user.username }}"
|
|
name="ldap_users"
|
|
disabled
|
|
><label class="table-checkbox-control-label" for="user_{{ loop.index }}"></label>
|
|
</td>
|
|
<td>{{ user.username }}</td>
|
|
<td>{{ user.email }}</td>
|
|
<td>{{ user.first_name }}</td>
|
|
<td>{{ user.last_name }}</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
<div class="d-flex mt-4">
|
|
<button type="submit" class="btn btn-danger mr-auto p-2">Ausführen</button>
|
|
<a href="{{ url('realm-user-list', args = [realm.id]) }}"
|
|
class="btn btn-secondary p-2">Abbrechen</a>
|
|
</div>
|
|
</form>
|
|
{% endblock %} |