Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions hypha/apply/users/templates/wagtailusers/users/edit.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,17 @@
{% extends "wagtailusers/users/edit.html" %}
{% load users_tags i18n %}

{% block actions %}
{{ block.super }}
{% user_2fa_enabled user as is_2fa_enabled %}
{% if is_2fa_enabled %}
<a class="button serious button-longrunning" href="{% url 'users:admin_disable' user.pk %}">
{% trans "Disable 2FA" %}
</a>
{% else %}
<button type="button" title="{% trans "This account does not have 2FA enabled." %}" class="button" disabled>{% trans "2FA is disabled" %}</button>
{% endif %}
{% endblock %}

{% block extra_fields %}
<li>{% include "wagtailadmin/shared/field.html" with field=form.full_name %}</li>
Expand Down
Loading