2017-01-03 19:55:01 +01:00
|
|
|
from django.conf.urls import url, include
|
2017-04-27 08:04:44 +02:00
|
|
|
from django.contrib.auth.decorators import login_required
|
2017-01-03 19:55:01 +01:00
|
|
|
from rest_framework import routers
|
|
|
|
from billard import views
|
|
|
|
|
|
|
|
router = routers.DefaultRouter()
|
2017-01-06 20:24:36 +01:00
|
|
|
router.register(r'location_data', views.LocationDataViewSet)
|
2017-01-03 19:55:01 +01:00
|
|
|
|
2017-04-27 08:04:44 +02:00
|
|
|
app_name = 'billard'
|
2017-01-03 19:55:01 +01:00
|
|
|
urlpatterns = [
|
2017-04-27 08:04:44 +02:00
|
|
|
# ex. /billard/
|
|
|
|
url(r'^$', login_required(views.LocationListView.as_view()), name='location_list'),
|
|
|
|
# ex. /billard/1/
|
|
|
|
url(r'^(?P<pk>[0-9]+)/$', login_required(views.LocationDetailView.as_view()), name='location_detail'),
|
|
|
|
# ex. /billard/1/accounting/
|
|
|
|
#url(r'^(?P<pk>[0-9]+)/accounting/$', views.ResultsView.as_view(), name='accounting_detail'),
|
|
|
|
|
|
|
|
|
|
|
|
#url(r'^$', views.index, name='carom_index'),
|
|
|
|
#url(r'^(?P<pk>[0-9]+)/$', views.LocationDataDetailView.as_view(), name='detail'),
|
|
|
|
#url(r'api/v1/', include(router.urls)),
|
|
|
|
#url(r'process_locationdata', views.process_locationdata, name='process_locationdata'),
|
|
|
|
#url(r'^accounting/$', views.AccountingView.as_view(), name='accounting'),
|
|
|
|
#url(r'accountmodal$', views.accountmodalview, name='accountmodal'),
|
|
|
|
#url(r'accoutmodal/confirm/(?P<pk>[0-9]+)$', views.accountmodalconfirmview, name="accountmodalconfirm")
|
|
|
|
# (?P<pk>[0-9]+)
|
2017-01-06 20:24:36 +01:00
|
|
|
]
|