workout/gym/urls.py

21 lines
1.2 KiB
Python

from django.urls import path
from . import views
# Wire up our API using automatic URL routing.
# Additionally, we include login URLs for the browsable API.
urlpatterns = [
path('', views.RoomListView.as_view(), name='rooms-list'),
path('rooms/<int:pk>/', views.RoomDetailView.as_view(), name='room-detail'),
path('equipment/add/', views.EquipmentCreateView.as_view(), name='equipment-create'),
path('equipment/<int:pk>/', views.EquipmentDetailView.as_view(), name='equipment-detail'),
path('setting/add/', views.SettingCreateView.as_view(), name='setting-create'),
path('setting/<int:pk>/', views.SettingUpdateView.as_view(), name='setting-edit'),
path('setting/<int:pk>/delete', views.SettingDeleteView.as_view(), name='setting-delete'),
path('session/start/', views.SessionCreateView.as_view(), name='session-start'),
path('session/<int:pk>/', views.SessionDetailView.as_view(), name='session-detail'),
path('round/add/', views.RoundCreateView.as_view(), name='round-create'),
path('theoretical-max/add/', views.TheoreticalMaxCreateView.as_view(), name='theoretical-max-create'),
# path('session/<int:pk>/delete', views.SessionDeleteView.as_view(), name='session-delete'),
]