Skip to content

Commit b12ed79

Browse files
committed
Merge branch 'master' into pr/141
2 parents bb2fb65 + 073dd3e commit b12ed79

12 files changed

+20
-15
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ htmlcov/
3333
.cache
3434
nosetests.xml
3535
coverage.xml
36+
coverage_html
3637

3738
# Translations
3839
*.mo

demo/demo/settings.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,9 +106,9 @@
106106
REST_SESSION_LOGIN = False
107107
EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'
108108
SITE_ID = 1
109-
ACCOUNT_EMAIL_REQUIRED = True
109+
ACCOUNT_EMAIL_REQUIRED = False
110110
ACCOUNT_AUTHENTICATION_METHOD = 'username'
111-
ACCOUNT_EMAIL_VERIFICATION = 'mandatory'
111+
ACCOUNT_EMAIL_VERIFICATION = 'optional'
112112

113113
REST_FRAMEWORK = {
114114
'DEFAULT_AUTHENTICATION_CLASSES': (

demo/templates/fragments/email_verification_form.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!-- Signup form -->
2-
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_verify_email' %}">
2+
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_verify_email' %}">{% csrf_token %}
33
<div class="form-group">
44
<label for="key" class="col-sm-2 control-label">Key</label>
55
<div class="col-sm-10">

demo/templates/fragments/login_form.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!-- Signup form -->
2-
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_login' %}">
2+
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_login' %}">{% csrf_token %}
33
<div class="form-group">
44
<label for="username" class="col-sm-2 control-label">Username</label>
55
<div class="col-sm-10">

demo/templates/fragments/password_change_form.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<!-- Signup form -->
2-
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_password_change' %}">
3-
2+
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_password_change' %}">{% csrf_token %}
43
<div class="form-group">
54
<label for="new_password1" class="col-sm-2 control-label">Password</label>
65
<div class="col-sm-10">

demo/templates/fragments/password_reset_confirm_form.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!-- Signup form -->
2-
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_password_reset_confirm' %}">
2+
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_password_reset_confirm' %}">{% csrf_token %}
33
<div class="form-group">
44
<label for="uid" class="col-sm-2 control-label">Uid</label>
55
<div class="col-sm-10">

demo/templates/fragments/password_reset_form.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!-- Signup form -->
2-
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_password_reset' %}">
2+
<form class="form-horizontal ajax-post" role="form" action="{% url 'rest_password_reset' %}">{% csrf_token %}
33
<div class="form-group">
44
<label for="email" class="col-sm-2 control-label">E-mail</label>
55
<div class="col-sm-10">

demo/templates/fragments/signup_form.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!-- Signup form -->
2-
<form class="form-horizontal ajax-post" id="signup" role="form" action="{% url 'rest_register' %}">
2+
<form class="form-horizontal ajax-post" id="signup" role="form" action="{% url 'rest_register' %}">{% csrf_token %}
33
<div class="form-group">
44
<label for="email" class="col-sm-2 control-label">Email</label>
55
<div class="col-sm-10">

demo/templates/fragments/user_details_form.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!-- Signup form -->
2-
<form class="form-horizontal" id="signup" role="form" action="{% url 'rest_user_details' %}">
2+
<form class="form-horizontal" id="signup" role="form" action="{% url 'rest_user_details' %}">{% csrf_token %}
33

44
<div class="form-group">
55
<label for="email" class="col-sm-2 control-label">Email</label>

docs/demo.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Do these steps to make it running (ideally in virtualenv).
1111
git clone https://github.com/Tivix/django-rest-auth.git
1212
cd django-rest-auth/demo/
1313
pip install -r requirements.pip
14-
python manage.py syncdb --settings=demo.settings --noinput
14+
python manage.py migrate --settings=demo.settings --noinput
1515
python manage.py runserver --settings=demo.settings
1616
1717
Now, go to ``http://127.0.0.1:8000/`` in your browser.

0 commit comments

Comments
 (0)