from django.conf.urls import url from user.views import RegisterView, user_active, UserLogin, UserInfoView, UserSiteView, UserOrderView, UserLogoutView urlpatterns = [ url(r'^register$', RegisterView.as_view(), name='register'), url(r'^active/(?P<token>.*)$', user_active, name='user_active'), url(r'^login$', UserLogin.as_view(), name='login'), url(r'logout$', UserLogoutView.as_view(), name='logout'), url(r'^info$', UserInfoView.as_view(), name='user_info'), url(r'^order$', UserOrderView.as_view(), name='order'), url(r'^site$', UserSiteView.as_view(), name='site') ]
""" User Application URLs Configuration =================================== """ from django.urls import path from user.views import (UserSignInView, UserSignUpView, UserLogoutView, UserProfileView) urlpatterns = [ path("login/", UserSignInView.as_view(), name="login"), path("logout/", UserLogoutView.as_view(), name="logout"), path("register/", UserSignUpView.as_view(), name="register"), path("profile/", UserProfileView.as_view(), name="profile"), ]
from django.urls import path from user.views import UserListView,UserCreateView,UserDeleteView,UserUpdateView,UserDetailView,UserLoginView,UserLogoutView app_name = 'user' urlpatterns = [ path('usuarios',UserListView.as_view(),name = 'listar_usuarios'), path('criarusuario',UserCreateView.as_view(),name = 'criar_usuario'), path('usuarios/<int:pk>/apagar',UserDeleteView.as_view(),name = 'deletar_usuario'), path('usuarios/<int:pk>/editar',UserUpdateView.as_view(),name = 'editar_usuario'), path('usuarios/<int:pk>/detalhar',UserDetailView.as_view(),name = 'detalhar_usuario'), path('usuarios/login',UserLoginView.as_view(),name='logar_usuario'), path('usuarios/logout',UserLogoutView.as_view(),name = 'deslogar_usuario'), ]
from django.urls import path from user.views import UserLogoutView, UserLoginView, UserRegistrationView app_name = 'user' urlpatterns = [ path('login/', UserLoginView.as_view(), name='login'), path('logout/', UserLogoutView.as_view(), name='logout'), path('register/', UserRegistrationView.as_view(), name='register') ]
from django.urls import path from rest_framework.authtoken.views import obtain_auth_token from user.views import UserLogoutView, UserRegisterView, UserSuggestionView, UserMeView, PasswordChangeView urlpatterns = [ path('login/', obtain_auth_token), path('logout/', UserLogoutView.as_view()), path('register/', UserRegisterView.as_view()), path('password_change/', PasswordChangeView.as_view()), path('me/', UserMeView.as_view()), path('suggestions/', UserSuggestionView.as_view()), ]