mirror of
https://github.com/Tivix/django-rest-auth.git
synced 2024-11-22 00:56:34 +03:00
add FAQ section in docs
This commit is contained in:
parent
059b0dcbab
commit
0fc4d56dae
|
@ -1,7 +1,9 @@
|
|||
Demo project
|
||||
============
|
||||
|
||||
To run demo project (ideally in virtualenv):
|
||||
The idea of creating demo project was to show how you can potentially use
|
||||
django-rest-auth app with jQuery on frontend.
|
||||
Do these steps to make it running (ideally in virtualenv).
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
|
|
17
docs/faq.rst
Normal file
17
docs/faq.rst
Normal file
|
@ -0,0 +1,17 @@
|
|||
FAQ
|
||||
===
|
||||
|
||||
1. Why account_confirm_email url is defined but it is not usable?
|
||||
|
||||
In /rest_auth/registration/urls.py we can find something like this:
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
url(r'^account-confirm-email/(?P<key>\w+)/$', TemplateView.as_view(),
|
||||
name='account_confirm_email'),
|
||||
|
||||
This url is used by django-allauth. Empty TemplateView is defined just to allow reverse() call inside app - when email with verification link is being sent.
|
||||
|
||||
You should override this view/url to handle it in your API client somehow and then, send post to /verify-email/ endpoint with proper key.
|
||||
If you don't want to use API on that step, then just use ConfirmEmailView view from:
|
||||
djang-allauth https://github.com/pennersr/django-allauth/blob/master/allauth/account/views.py#L190
|
|
@ -22,6 +22,7 @@ Contents
|
|||
API endpoints <api_endpoints>
|
||||
Configuration <configuration>
|
||||
Demo project <demo>
|
||||
FAQ <faq>
|
||||
Changelog <changelog>
|
||||
|
||||
|
||||
|
|
|
@ -14,7 +14,21 @@ Features
|
|||
* Password reset via e-mail
|
||||
* Social Media authentication
|
||||
|
||||
|
||||
Apps structure
|
||||
--------------
|
||||
|
||||
* ``rest_auth`` has basic auth functionality like login, logout, password reset and password change
|
||||
* ``rest_auth.registration`` has logic related with registration and social media authentication
|
||||
|
||||
|
||||
Angular app
|
||||
-----------
|
||||
|
||||
- Tivix has also created angular module which uses API endpoints from this app - `angular-django-registration-auth <https://github.com/Tivix/angular-django-registration-auth>`_
|
||||
|
||||
|
||||
Demo project
|
||||
------------
|
||||
|
||||
- You can also check our :doc:`Demo Project </demo>` which is using jQuery on frontend.
|
||||
|
|
|
@ -7,7 +7,7 @@ urlpatterns = patterns('',
|
|||
url(r'^$', Register.as_view(), name='rest_register'),
|
||||
url(r'^verify-email/$', VerifyEmail.as_view(), name='rest_verify_email'),
|
||||
|
||||
# These two views are used in django-allauth and empty TemplateView were
|
||||
# This url is used by django-allauth and empty TemplateView is
|
||||
# defined just to allow reverse() call inside app, for example when email
|
||||
# with verification link is being sent, then it's required to render email
|
||||
# content.
|
||||
|
@ -18,8 +18,6 @@ urlpatterns = patterns('',
|
|||
# If you don't want to use API on that step, then just use ConfirmEmailView
|
||||
# view from:
|
||||
# djang-allauth https://github.com/pennersr/django-allauth/blob/master/allauth/account/views.py#L190
|
||||
url(r'^account-email-verification-sent/$', TemplateView.as_view(),
|
||||
name='account_email_verification_sent'),
|
||||
url(r'^account-confirm-email/(?P<key>\w+)/$', TemplateView.as_view(),
|
||||
name='account_confirm_email'),
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue
Block a user