mirror of
https://github.com/Tivix/django-rest-auth.git
synced 2025-02-06 21:20:32 +03:00
commit
18e98d333b
|
@ -3,9 +3,9 @@ python:
|
|||
- "2.7"
|
||||
- "3.5"
|
||||
env:
|
||||
- DJANGO=1.8.17
|
||||
- DJANGO=1.9.12
|
||||
- DJANGO=1.10.4
|
||||
- DJANGO=1.8.18
|
||||
- DJANGO=1.10.7
|
||||
- DJANGO=1.11.1
|
||||
install:
|
||||
- pip install -q Django==$DJANGO
|
||||
- pip install coveralls
|
||||
|
|
|
@ -36,7 +36,7 @@ Configuration
|
|||
You can define your custom serializers for registration endpoint.
|
||||
Possible key values:
|
||||
|
||||
- REGISTER_SERIALIZER - serializer class in ``rest_auth.register.views.RegisterView``, default value ``rest_auth.registration.serializers.RegisterSerializer``
|
||||
- REGISTER_SERIALIZER - serializer class in ``rest_auth.registration.views.RegisterView``, default value ``rest_auth.registration.serializers.RegisterSerializer``
|
||||
|
||||
.. note:: The custom REGISTER_SERIALIZER must define a ``def save(self, request)`` method that returns a user model instance
|
||||
|
||||
|
|
|
@ -31,6 +31,12 @@ Installation
|
|||
url(r'^rest-auth/', include('rest_auth.urls'))
|
||||
)
|
||||
|
||||
4. Migrate your database
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
python manage.py migrate
|
||||
|
||||
|
||||
You're good to go now!
|
||||
|
||||
|
@ -151,13 +157,15 @@ If you are using Twitter for your social authentication, it is a bit different s
|
|||
JWT Support (optional)
|
||||
----------------------
|
||||
|
||||
By default, ``django-rest-auth`` uses Django's Token-based authentication. If you want to use JWT authentication, you need to install the following:
|
||||
By default ``django-rest-auth`` uses Django's Token-based authentication. If you want to use JWT authentication, follow these steps:
|
||||
|
||||
1. Install ``django-rest-framework-jwt`` http://getblimp.github.io/django-rest-framework-jwt/ . Right now this is the only supported JWT library.
|
||||
1. Install `django-rest-framework-jwt <http://getblimp.github.io/django-rest-framework-jwt/>`_
|
||||
- ``django-rest-framework-jwt`` is currently the only supported JWT library.
|
||||
2. The ``JWT_PAYLOAD_HANDLER`` and ``JWT_ENCODE_HANDLER`` settings are imported from the ``django-rest-framework-jwt`` settings object.
|
||||
- Refer to `the library's documentation <http://getblimp.github.io/django-rest-framework-jwt/#additional-settings>`_ for information on using different encoders.
|
||||
|
||||
2. Add the following to your settings
|
||||
3. Add the following configuration value to your settings file to enable JWT authentication.
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
REST_USE_JWT = True
|
||||
|
||||
|
|
BIN
rest_auth/locale/pl/LC_MESSAGES/django.mo
Normal file
BIN
rest_auth/locale/pl/LC_MESSAGES/django.mo
Normal file
Binary file not shown.
99
rest_auth/locale/pl/LC_MESSAGES/django.po
Normal file
99
rest_auth/locale/pl/LC_MESSAGES/django.po
Normal file
|
@ -0,0 +1,99 @@
|
|||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
||||
# This file is distributed under the same license as the PACKAGE package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2017-03-05 21:56-0800\n"
|
||||
"PO-Revision-Date: 2017-03-11 12:10+0100\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
|
||||
"Language-Team: \n"
|
||||
"X-Generator: Poedit 1.8.11\n"
|
||||
"Last-Translator: \n"
|
||||
"Language: pl\n"
|
||||
|
||||
#: registration/serializers.py:53
|
||||
msgid "View is not defined, pass it as a context variable"
|
||||
msgstr "Widok nie został zdefiniowany, przekaż go przez zmienną \"context\""
|
||||
|
||||
#: registration/serializers.py:58
|
||||
msgid "Define adapter_class in view"
|
||||
msgstr "Zdefiniuj \"adapter_class\" w widoku"
|
||||
|
||||
#: registration/serializers.py:77
|
||||
msgid "Define callback_url in view"
|
||||
msgstr "Zdefiniuj \"callback_url\" w widoku"
|
||||
|
||||
#: registration/serializers.py:81
|
||||
msgid "Define client_class in view"
|
||||
msgstr "Zdefiniuj \"client_class\" w widoku"
|
||||
|
||||
#: registration/serializers.py:102
|
||||
msgid "Incorrect input. access_token or code is required."
|
||||
msgstr "Podano błędne dane. \"access_token\" lub \"code\" są wymagne."
|
||||
|
||||
#: registration/serializers.py:111
|
||||
msgid "Incorrect value"
|
||||
msgstr "Niepoprawna wartość."
|
||||
|
||||
#: registration/serializers.py:140
|
||||
msgid "A user is already registered with this e-mail address."
|
||||
msgstr "Istnieje już użytkownik z takim adresem email."
|
||||
|
||||
#: registration/serializers.py:148
|
||||
msgid "The two password fields didn't match."
|
||||
msgstr "Hasła nie są identyczne."
|
||||
|
||||
#: registration/views.py:44
|
||||
msgid "Verification e-mail sent."
|
||||
msgstr "Email weryfikacyjny został wysłany."
|
||||
|
||||
#: registration/views.py:91
|
||||
msgid "ok"
|
||||
msgstr "ok"
|
||||
|
||||
#: serializers.py:30
|
||||
msgid "Must include \"email\" and \"password\"."
|
||||
msgstr "Musisz podać email i hasło."
|
||||
|
||||
#: serializers.py:41
|
||||
msgid "Must include \"username\" and \"password\"."
|
||||
msgstr "Musisz podać nazwę użytkownika i hasło."
|
||||
|
||||
#: serializers.py:54
|
||||
msgid "Must include either \"username\" or \"email\" and \"password\"."
|
||||
msgstr "Musisz podać nazwę użytkownika (lub email) i hasło."
|
||||
|
||||
#: serializers.py:95
|
||||
msgid "User account is disabled."
|
||||
msgstr "Konto użytkownika zostało wyłączone."
|
||||
|
||||
#: serializers.py:98
|
||||
msgid "Unable to log in with provided credentials."
|
||||
msgstr "Podane dane do logowania są niepoprawne."
|
||||
|
||||
#: serializers.py:107
|
||||
msgid "E-mail is not verified."
|
||||
msgstr "Email nie został zweryfikowany."
|
||||
|
||||
#: views.py:126
|
||||
msgid "Successfully logged out."
|
||||
msgstr "Wylogowano."
|
||||
|
||||
#: views.py:174
|
||||
msgid "Password reset e-mail has been sent."
|
||||
msgstr "Email z linkiem do resetu hasła został wysłany."
|
||||
|
||||
#: views.py:200
|
||||
msgid "Password has been reset with the new password."
|
||||
msgstr "Hasło zostało zresetowane."
|
||||
|
||||
#: views.py:222
|
||||
msgid "New password has been saved."
|
||||
msgstr "Nowe hasło zostało zapisane."
|
Loading…
Reference in New Issue
Block a user