29 lines
1.8 KiB

"""
Soubor sloužící jako router, tj. zde se definují url adresy a na co ukazují:
- ``prihlasit/`` (login) :class:`~various.autentizace.views.LoginView`
- ``login/`` :class:`django.views.generic.base.RedirectView` předchozího
- ``odhlasit/`` (logout) :class:`~various.autentizace.views.LogoutView`
- ``logout/`` :class:`django.views.generic.base.RedirectView` předchozího
- ``reset-hesla/`` (reset_password) :class:`~various.autentizace.views.PasswordResetView`
- ``zmena-hesla/`` (change_password) :class:`~various.autentizace.views.PasswordChangeView`
- ``zmena-hesla/2/`` (reset_password_done) :class:`~various.autentizace.views.PasswordResetDoneView`
- ``reset-hesla/potvrzeni/<uidb64>/<token>/`` (reset_password_confirm) :class:`~various.autentizace.views.PasswordResetConfirmView`
- ``reset-hesla/hotovo/`` (reset_password_complete) :class:`~various.autentizace.views.PasswordResetCompleteView`
"""
from django.urls import path
from . import views
from django.views.generic.base import RedirectView
urlpatterns = [
path('prihlasit/', views.LoginView.as_view(), name='login'),
path('login/', RedirectView.as_view(pattern_name='login', permanent=True, query_string=True)),
path('odhlasit/', views.LogoutView.as_view(), name='logout'),
path('logout/', RedirectView.as_view(pattern_name='logout', permanent=True, query_string=True)),
path('reset-hesla/', views.PasswordResetView.as_view(), name='reset_password'),
path('zmena-hesla/', views.PasswordChangeView.as_view(), name='change_password'),
path('reset-hesla/2/', views.PasswordResetDoneView.as_view(), name='reset_password_done'),
path('reset-hesla/potvrzeni/<uidb64>/<token>/', views.PasswordResetConfirmView.as_view(), name='reset_password_confirm'),
path('reset-hesla/hotovo/', views.PasswordResetCompleteView.as_view(), name='reset_password_complete'),
]