File tree 3 files changed +49
-0
lines changed
allauth_ui/templates/account
3 files changed +49
-0
lines changed Original file line number Diff line number Diff line change
1
+ {# -*- engine:django -*- #}
2
+ {% extends "account/confirm_login_code.html" %}
3
+ {% load i18n %}
4
+ {% load allauth %}
5
+ {% load allauth_ui %}
6
+ {% load widget_tweaks %}
7
+ {% block content %}
8
+ {% trans "Sign In" as heading %}
9
+ {% #container heading=heading %}
10
+ < div class ="py-3 "> {% blocktranslate %}Enter Sign-In Code{% endblocktranslate %}</ div >
11
+ < div class ="py-3 ">
12
+ {% setvar email_link %}
13
+ < a href ="mailto:{{ email }} "> {{ email }}</ a >
14
+ {% endsetvar %}
15
+ {% blocktranslate %}We’ve sent a code to {{ email_link }}. The code expires shortly, so please enter it soon.{% endblocktranslate %}
16
+ </ div >
17
+ {% url 'account_confirm_login_code' as action_url %}
18
+ {% #form form=form url=action_url button_text=heading %}
19
+ {{ redirect_field }}
20
+ {% csrf_token %}
21
+ {% /form %}
22
+ < button type ="submit " class ="btn btn-red " form ="logout-from-stage "> {% translate "Cancel" %}</ button >
23
+ < form id ="logout-from-stage "
24
+ method ="post "
25
+ action ="{% url 'account_logout' %} ">
26
+ < input type ="hidden " name ="next " value ="{% url 'account_login' %} ">
27
+ {% csrf_token %}
28
+ </ form >
29
+ {% /container %}
30
+ {% endblock content %}
31
+ {% comment %}{% endcomment %}
Original file line number Diff line number Diff line change
1
+ {% extends "account/request_login_code.html" %}
2
+ {% load i18n %}
3
+ {% load allauth_ui %}
4
+ {% load widget_tweaks %}
5
+ {% block content %}
6
+ {% trans "Mail me a sign-in code" as heading %}
7
+ {% #container heading=heading %}
8
+ < div class ="py-3 ">
9
+ {% blocktranslate %}You will receive an email containing a special code for a password-free sign-in.{% endblocktranslate %}
10
+ </ div >
11
+ {% url 'account_request_login_code' as action_url %}
12
+ {% #form form=form url=action_url button_text=heading %}
13
+ {{ redirect_field }}
14
+ {% csrf_token %}
15
+ {% /form %}
16
+ {% /container %}
17
+ {% endblock content %}
Original file line number Diff line number Diff line change 111
111
ACCOUNT_EMAIL_VERIFICATION = "mandatory"
112
112
ACCOUNT_AUTHENTICATION_METHOD = "email"
113
113
ACCOUNT_LOGIN_ATTEMPTS_LIMIT = 1000
114
+ ACCOUNT_LOGIN_BY_CODE_ENABLED = "true"
114
115
115
116
BASE_DIR = Path (__file__ ).parent .parent
116
117
You can’t perform that action at this time.
0 commit comments