Fix possibility to realm update as non super admin
This commit is contained in:
parent
cefacbb7a0
commit
07c6d4d89f
@ -6,10 +6,11 @@
|
||||
<p>LDAP OU: {{ realm.ldap_base_dn }}</p>
|
||||
<p>Email: {{ realm.email }}</p>
|
||||
<p>Admin Gruppe: {{ realm.admin_group }}</p>
|
||||
|
||||
{% block realm_form %}
|
||||
<h2><a href="{{ url('realm-update', args=[realm.id]) }}">Bereichsinformationen anpassen</a></h2>
|
||||
{% endblock %}
|
||||
{% if request.user.is_superuser %}
|
||||
{% block realm_form %}
|
||||
<h2><a href="{{ url('realm-update', args=[realm.id]) }}">Bereichsinformationen anpassen</a></h2>
|
||||
{% endblock %}
|
||||
{% endif %}
|
||||
|
||||
<h2><a href="{{ url('realm-user-add', args=[realm.id]) }}">Nutzer hinzufügen</a></h2>
|
||||
{% block user_content %}
|
||||
|
||||
@ -1,8 +1,10 @@
|
||||
{% extends 'realm/realm_detailed.jinja2' %}
|
||||
{% block realm_form %}
|
||||
<form method="post">
|
||||
<input type="hidden" name="csrfmiddlewaretoken" value="{{ csrf_token }}">
|
||||
{{ form.as_p()|safe }}
|
||||
<button type="submit">Speichern</button>
|
||||
</form>
|
||||
{% if form %}
|
||||
<form method="post">
|
||||
<input type="hidden" name="csrfmiddlewaretoken" value="{{ csrf_token }}">
|
||||
{{ form.as_p()|safe }}
|
||||
<button type="submit">Speichern</button>
|
||||
</form>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user