carom-server/billard/urls.py

16 lines
552 B
Python
Raw Normal View History

2017-01-03 19:55:01 +01:00
from django.conf.urls import url, include
from rest_framework import routers
from billard import views
router = routers.DefaultRouter()
router.register(r'clients', views.ClientViewSet)
router.register(r'locations', views.LocationViewSet)
router.register(r'tables', views.TableViewSet)
2017-01-06 20:24:36 +01:00
router.register(r'location_data', views.LocationDataViewSet)
2017-01-03 19:55:01 +01:00
urlpatterns = [
url(r'^$', views.IndexView.as_view(), name='index'),
2017-01-09 20:42:59 +01:00
url(r'^(?P<pk>[0-9]+)/$', views.LocationDataDetailView.as_view(), name='detail'),
2017-01-03 19:55:01 +01:00
url(r'api/v1/', include(router.urls)),
2017-01-06 20:24:36 +01:00
]