urls.py
2.3 KB
from django.urls import path, re_path
from . import views
from django.contrib.auth import views as auth_views
from .forms import UserPasswordResetForm
urlpatterns = [
path('users', views.users, name="users"),
re_path(r'^create$', views.create_user, name="create_user"),
re_path(r'^forgotten_password$', views.forgotten_password, name="forgotten_password"),
re_path(r'^creation_validate$', views.user_signup_validation, name="user_signup_validation"),
re_path(r'^login$', views.login_validation, name="login_validation"),
re_path(r'^logout$', views.user_logout, name="user_logout"),
path('signin', views.user_signin, name="user_signin"),
path('sp_profile', views.superoperator_return, name="sp_profile"),
path('users/<int:pk>', views.user_detail_view, name='user_detail'),
path('users_delete/<int:pk>', views.delete_user, name='user-delete'),
path('users/<int:pk>/edit', views.user_detail_edit, name='user-edit'),
path('user-status/<int:pk>/<int:current_user_id>', views.change_activate, name='change_activate'),
path("set_active_role", views.set_active_role,name="set_active_role"),
path("password-reset", auth_views.PasswordResetView.as_view( template_name="user_manager/password_reset.html",email_template_name="user_manager/password_reset_email.html"), name="password_reset"),
path("password-reset/done/", auth_views.PasswordResetDoneView.as_view( template_name="user_manager/password_reset_done.html"), name="password_reset_done"),
path("password-reset-confirm/<uidb64>/<token>", auth_views.PasswordResetConfirmView.as_view( template_name="user_manager/password_reset_confirm.html"), name="password_reset_confirm"),
path("password-reset-complete/", auth_views.PasswordResetCompleteView.as_view( template_name="user_manager/password_reset_complete.html"), name="password_reset_complete"),
path('change-password/',auth_views.PasswordChangeView.as_view(template_name='user_manager/change_password.html', success_url = '/'),name="password_change"),
path('roles_description', views.roles_description, name="roles_description")
]