aemo_fr/templates/aemo/utilisateur_edit.html
2024-06-03 16:49:01 +02:00

49 lines
2.3 KiB
HTML
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{% extends "base.html" %}
{% block extrastyle %}
<style>span.helptext { display: none; }</style>
{% endblock %}
{% block content %}
<div class="row border-bottom mb-3">
<div class="col"><p class="lead">Utilisateur</p></div>
{% if form.instance.pk %}
<div class="col text-end">
<form class="form-reinit form inline" action="{% url 'utilisateur-password-reinit' object.pk %}" method="post">{% csrf_token %}
<button id="reinit" class="btn btn-outline-primary btn-sm">Réinit. mot de passe</button>
</form>
<form class="form-renit form inline" action="{% url 'utilisateur-otp-device-reinit' object.pk %}" method="post">{% csrf_token %}
<button id="otp-reinit" class="btn btn-outline-primary btn-sm">Réinit. du mobile</button>
</form>
<a class="btn btn-outline-primary btn-sm" href="{% url 'utilisateur-journalacces' form.instance.pk %}">Journal daccès</a>
</div>
{% endif %}
</div>
<div class="row justify-content-center">
<div class="col-8">
<form action="." method="post">
{% csrf_token %}
<table class="table table-sm">
{{ form.as_table }}
</table>
<div id="actions" class="row border-top mt-2">
{% if form.instance.pk %}
<div class="col mt-3">
{% if view.delete_url %}
<button class="btn btn-sm btn-danger" name="delete" type="submit"
data-confirm="Voulez-vous vraiment désactiver cet utilisateur ?"
formaction="{{ view.delete_url }}" title="Cet utilisateur n'apparaîtra plus dans les listes"
>Désactiver</button>
{% endif %}
</div>
{% endif %}
<div class="col mt-3 text-end">
<a class="btn btn-sm btn-secondary" href="javascript: history.go(-1)">Annuler</a>
<button class="btn btn-sm btn-success" name="save" type="submit">Enregistrer</button>
</div>
</div>
</form>
</div>
</div>
{% endblock %}