1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-12-03 17:36:05 +00:00

fix(admin): a user or group form opened before another change does not undo it

The user and group edit forms send back every field they show. A form
opened before another administrator blocked the user, took away a group
or a permission, or changed a group's members, put those back when it
was saved for another change. The forms now send a fingerprint of what
they showed, and a user or group changed meanwhile is shown again as it
is now, with nothing saved. The user's password and last login are no
change of the form.
This commit is contained in:
catborise 2026-11-13 14:29:50 +03:00
parent 35a5bbdb62
commit ab77b198f2
12 changed files with 208 additions and 121 deletions

View file

@ -10,6 +10,7 @@
{% block content %}
<form id="create-update" method="post">
{% csrf_token %}
{% if seen %}<input type="hidden" name="seen" value="{{ seen }}">{% endif %}
{% bootstrap_form_errors form type="non_fields" %}
<section class="form-section">

View file

@ -11,6 +11,7 @@
{# who the user is, what they manage, what they may use, then what more they may do #}
<form id="create-update" method="post">
{% csrf_token %}
{% if seen %}<input type="hidden" name="seen" value="{{ seen }}">{% endif %}
{% bootstrap_form_errors user_form type="non_fields" %}
<section class="form-section">