63 lines
1.6 KiB
HTML
63 lines
1.6 KiB
HTML
{{define "title"}}Liste des utilisateurs |{{end}}
|
|
|
|
{{define "admenu"}}
|
|
{{if .Login.CanAdmin}}
|
|
<li><a href="#">Administration</a>
|
|
<ul class="submenu">
|
|
<li><a href="/admin/activate">Administrer LDAP</a>
|
|
<li><a href="/admin/activate">Activer des Utilisateur·ices</a></li>
|
|
<li><a href="/admin/users">Utilisateur·ices</a></li>
|
|
<li><a href="/admin/groups">Groupes</a></li>
|
|
</ul>
|
|
</li>
|
|
{{end}}
|
|
{{if .Login}}
|
|
<li>< <a href="#">Compte</a>
|
|
<ul class="submenu">
|
|
<a href="/logout">Se déconnecter</a>
|
|
<li><a href="/gpas">Mal de passe oublié</a></li>
|
|
<li><a href="/invite/new_account">S'enregistrer</a></li>
|
|
</ul></li>
|
|
{{else}}
|
|
<li> < <a href="/">Se connecter</a></li>
|
|
{{end}}
|
|
{{end}}
|
|
|
|
|
|
{{define "body"}}
|
|
|
|
<div class="d-flex">
|
|
<h2>Liste des utilisateurs</h2>
|
|
<a class="ml-auto btn btn-success" href="/admin/create/user/{{.UserBaseDN}}">Nouvel utilisateur</a>
|
|
</div>
|
|
|
|
<table class="table mt-4">
|
|
<thead>
|
|
<th scope="col"></th>
|
|
<th scope="col">Identifiant</th>
|
|
<th scope="col">Nom complet</th>
|
|
<th scope="col">Email</th>
|
|
</thead>
|
|
<tbody>
|
|
{{with $root := .}}
|
|
{{range $user := $root.Users}}
|
|
<tr>
|
|
<td>
|
|
<a href="/admin/unactivate/{{ $user.GetAttributeValue "cn" }}">
|
|
Dèsactiver
|
|
</a>
|
|
</td>
|
|
<td>
|
|
<a href="/admin/ldap/{{$user.DN}}">
|
|
{{$user.GetAttributeValue $root.UserNameAttr}}
|
|
</a>
|
|
</td>
|
|
<td>{{$user.GetAttributeValue "displayName"}}</td>
|
|
<td>{{$user.GetAttributeValue "mail"}}</td>
|
|
</tr>
|
|
{{end}}
|
|
{{end}}
|
|
</tbody>
|
|
</table>
|
|
|
|
{{end}}
|