Working state
This commit is contained in:
@@ -54,10 +54,12 @@
|
||||
<label for="role" class="form-container__label">
|
||||
<span>Rôle</span>
|
||||
<select id="role" name="role" class="form-container__select">
|
||||
<option value="user">Utilisateur</option>
|
||||
<option value="editor">Éditeur</option>
|
||||
{% for role in assignableRoles %}
|
||||
<option value="{{ role }}">{% if role == 'editor' %}Éditeur{% else %}Utilisateur{% endif %}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</label>
|
||||
<small class="form-container__hint">Le rôle administrateur reste réservé au provisionnement initial.</small>
|
||||
</p>
|
||||
|
||||
<div class="form-container__actions">
|
||||
|
||||
@@ -58,9 +58,11 @@
|
||||
<input type="hidden" name="{{ csrf.keys.value }}" value="{{ csrf.value }}">
|
||||
<div class="u-inline-actions">
|
||||
<select name="role" class="admin-table__role-select">
|
||||
<option value="user" {% if user.role == 'user' %}selected{% endif %}>Utilisateur</option>
|
||||
<option value="editor" {% if user.role == 'editor' %}selected{% endif %}>Éditeur</option>
|
||||
<option value="admin" {% if user.role == 'admin' %}selected{% endif %}>Admin</option>
|
||||
{% for role in assignableRoles %}
|
||||
<option value="{{ role }}" {% if user.role == role %}selected{% endif %}>
|
||||
{% if role == 'editor' %}Éditeur{% else %}Utilisateur{% endif %}
|
||||
</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
<button type="submit" class="btn btn--sm btn--secondary">Modifier</button>
|
||||
</div>
|
||||
@@ -89,6 +91,8 @@
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
{% include 'partials/_pagination.twig' with { pagination: pagination } %}
|
||||
{% else %}
|
||||
<p><em>Aucun utilisateur.</em></p>
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user