ft_transcendence/profiles/urls.py

11 lines
509 B
Python
Raw Normal View History

2023-10-24 12:42:43 -04:00
from django.urls import path
2023-12-06 09:19:41 -05:00
from django.conf import settings
from django.conf.urls.static import static
2023-10-24 12:42:43 -04:00
2023-12-06 09:19:41 -05:00
from . import viewsets
2023-10-24 12:42:43 -04:00
urlpatterns = [
2023-12-16 10:42:30 -05:00
path("me", viewsets.MyProfileViewSet.as_view({'patch': 'partial_update', 'get': 'retrieve'}), name="my_profile_page"),
path("<int:pk>", viewsets.ProfileViewSet.as_view({'get': 'retrieve'}), name="profile_page"),
2023-12-08 11:36:41 -05:00
path("", viewsets.ProfileViewSet.as_view({'get': 'list'}), name="profiles_list"),
2023-12-06 09:19:41 -05:00
] + static("/static/avatars/", document_root="./avatars")