urls.py 680 B

123456789101112131415161718
  1. from django.urls import path
  2. from django.conf import settings
  3. from django.conf.urls.static import static
  4. from .views import *
  5. urlpatterns = [
  6. path('', HomePageView.as_view(), name='base'),
  7. path('login/', LoginUserView.as_view(), name='login'),
  8. path('logout/', LogoutUserView.as_view(), name='logout'),
  9. path('service/', ProductListView.as_view(), name='service'),
  10. path('<int:pk>/service/', ProductDetailView.as_view(), name='detail'),
  11. path('accounts/profile/', ProfileListView.as_view(), name='profile'),
  12. path('accounts/register/', RegistrationListView.as_view(), name='register'),
  13. ] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)