File tree Expand file tree Collapse file tree 5 files changed +33
-0
lines changed Expand file tree Collapse file tree 5 files changed +33
-0
lines changed Original file line number Diff line number Diff line change 11
11
name = 'email-verification' ),
12
12
url (r'^login/$' , TemplateView .as_view (template_name = "login.html" ),
13
13
name = 'login' ),
14
+ url (r'^logout/$' , TemplateView .as_view (template_name = "logout.html" ),
15
+ name = 'logout' ),
14
16
url (r'^password-reset/$' ,
15
17
TemplateView .as_view (template_name = "password_reset.html" ),
16
18
name = 'password-reset' ),
Original file line number Diff line number Diff line change 40
40
< li class ="divider "> </ li >
41
41
<!-- these pages require user token -->
42
42
< li > < a href ="{% url 'user-details' %} "> User details</ a > </ li >
43
+ < li > < a href ="{% url 'logout' %} "> Logout</ a > </ li >
43
44
< li > < a href ="{% url 'password-change' %} "> Password change</ a > </ li >
44
45
</ ul >
45
46
</ li >
Original file line number Diff line number Diff line change
1
+ {% block content %}
2
+
3
+ < form class ="form-horizontal ajax-post " role ="form " action ="{% url 'rest_logout' %} "> {% csrf_token %}
4
+ < div class ="form-group ">
5
+ < label for ="token " class ="col-sm-2 control-label "> User Token</ label >
6
+ < div class ="col-sm-4 ">
7
+ < input name ="token " type ="text " class ="form-control " id ="token " placeholder ="Token ">
8
+ < p class ="help-block "> Token received after login</ p >
9
+ </ div >
10
+ </ div >
11
+
12
+ < div class ="form-group ">
13
+ < div class ="col-sm-offset-2 col-sm-10 ">
14
+ < button type ="submit " class ="btn btn-default "> Login</ button >
15
+ </ div >
16
+ </ div >
17
+
18
+ < div class ="form-group api-response "> </ div >
19
+ </ form >
20
+ {% endblock %}
Original file line number Diff line number Diff line change
1
+ {% extends "base.html" %}
2
+
3
+ {% block content %}
4
+ < div class ="row ">
5
+ < h3 > Logout</ h3 > < hr />
6
+ {% include "fragments/logout_form.html" %}
7
+ </ div >
8
+ {% endblock %}
Original file line number Diff line number Diff line change 13
13
14
14
- /rest-auth/logout/ (POST)
15
15
16
+ - token
17
+
16
18
- /rest-auth/password/reset/ (POST)
17
19
18
20
- email
You can’t perform that action at this time.
0 commit comments