| 1 |
{% extends "account/base_entrance.html" %} |
| 2 |
{% load i18n %} |
| 3 |
{% load allauth account %} |
| 4 |
{% block content %} |
| 5 |
{% setvar title_ %} |
| 6 |
{% block title %}{% endblock %} |
| 7 |
{% endsetvar %} |
| 8 |
{% setvar action_url %} |
| 9 |
{% block action_url %}{% endblock %} |
| 10 |
{% endsetvar %} |
| 11 |
{% setvar extra_tags %} |
| 12 |
{% block extra_tags %}{% endblock %} |
| 13 |
{% endsetvar %} |
| 14 |
{% setvar form_tags %} |
| 15 |
entrance,{{ extra_tags }} |
| 16 |
{% endsetvar %} |
| 17 |
{% setvar submit_button_tags %} |
| 18 |
confirm,{{ extra_tags }} |
| 19 |
{% endsetvar %} |
| 20 |
{% setvar recipient %} |
| 21 |
{% block recipient %}{% endblock %} |
| 22 |
{% endsetvar %} |
| 23 |
{% element h1 %} |
| 24 |
{{ title_ }} |
| 25 |
{% endelement %} |
| 26 |
{% element p %} |
| 27 |
{% blocktranslate %}We've sent a code to {{ recipient }}. The code expires shortly, so please enter it soon.{% endblocktranslate %} |
| 28 |
{% endelement %} |
| 29 |
{% element form form=verify_form method="post" action=action_url tags=form_tags %} |
| 30 |
{% slot body %} |
| 31 |
{% csrf_token %} |
| 32 |
{% element fields form=verify_form unlabeled=True %} |
| 33 |
{% endelement %} |
| 34 |
{{ redirect_field }} |
| 35 |
{% endslot %} |
| 36 |
{% slot actions %} |
| 37 |
{% element button_group %} |
| 38 |
{% element button type="submit" tags=submit_button_tags %} |
| 39 |
{% translate "Confirm" %} |
| 40 |
{% endelement %} |
| 41 |
{% if can_resend %} |
| 42 |
{% element button form="resend" tags="outline,resend" %} |
| 43 |
{% translate "Request new code" %} |
| 44 |
{% endelement %} |
| 45 |
{% endif %} |
| 46 |
{% if cancel_url %} |
| 47 |
{% element button href=cancel_url tags="outline,cancel" %} |
| 48 |
{% translate "Cancel" %} |
| 49 |
{% endelement %} |
| 50 |
{% else %} |
| 51 |
{% element button type="submit" form="logout-from-stage" tags="outline,cancel" %} |
| 52 |
{% translate "Cancel" %} |
| 53 |
{% endelement %} |
| 54 |
{% endif %} |
| 55 |
{% endelement %} |
| 56 |
{% endslot %} |
| 57 |
{% endelement %} |
| 58 |
<form id="resend" method="post" action="{{ action_url }}"> |
| 59 |
<input type="hidden" name="action" value="resend"> |
| 60 |
{{ redirect_field }} |
| 61 |
{% csrf_token %} |
| 62 |
</form> |
| 63 |
{% if not cancel_url %} |
| 64 |
<form id="logout-from-stage" |
| 65 |
method="post" |
| 66 |
action="{% url 'account_logout' %}"> |
| 67 |
<input type="hidden" name="next" value="{% url 'account_login' %}"> |
| 68 |
{% csrf_token %} |
| 69 |
</form> |
| 70 |
{% endif %} |
| 71 |
{% setvar summary_ %} |
| 72 |
{% block change_title %}{% endblock %} |
| 73 |
{% endsetvar %} |
| 74 |
{% if can_change %} |
| 75 |
{% element details open=change_form.errors %} |
| 76 |
{% slot summary %} |
| 77 |
{{ summary_ }} |
| 78 |
{% endslot %} |
| 79 |
{% slot body %} |
| 80 |
{% element form form=change_form method="post" action=action_url %} |
| 81 |
{% slot body %} |
| 82 |
{% csrf_token %} |
| 83 |
{% element fields form=change_form unlabeled=True %} |
| 84 |
{% endelement %} |
| 85 |
{{ redirect_field }} |
| 86 |
{% endslot %} |
| 87 |
{% slot actions %} |
| 88 |
{% element button name="action" value="change" type="submit" %} |
| 89 |
Change |
| 90 |
{% endelement %} |
| 91 |
{% endslot %} |
| 92 |
{% endelement %} |
| 93 |
{% endslot %} |
| 94 |
{% endelement %} |
| 95 |
{% endif %} |
| 96 |
{% endblock content %} |