Fix all url declarations to specifying starts with (^).

This commit is contained in:
Christopher Charbonneau Wells 2017-08-21 19:19:48 -04:00
parent 0b8205a830
commit 7bffb41718
3 changed files with 32 additions and 31 deletions

View File

@ -16,4 +16,5 @@ urlpatterns = [
url(r'', include('api.urls', namespace='api')), url(r'', include('api.urls', namespace='api')),
url(r'', include('core.urls')), url(r'', include('core.urls')),
url(r'', include('dashboard.urls')), url(r'', include('dashboard.urls')),
url(r'', include('reports.urls')),
] ]

View File

@ -6,60 +6,60 @@ from django.conf.urls import url
from . import views from . import views
urlpatterns = [ urlpatterns = [
url(r'children/$', views.ChildList.as_view(), name='child-list'), url(r'^children/$', views.ChildList.as_view(), name='child-list'),
url(r'children/add/$', views.ChildAdd.as_view(), name='child-add'), url(r'^children/add/$', views.ChildAdd.as_view(), name='child-add'),
url(r'children/(?P<pk>[0-9]+)/$', views.ChildUpdate.as_view(), url(r'^children/(?P<pk>[0-9]+)/$', views.ChildUpdate.as_view(),
name='child-update'), name='child-update'),
url(r'children/(?P<slug>[^/.]+)/$', views.ChildUpdate.as_view(), url(r'^children/(?P<slug>[^/.]+)/$', views.ChildUpdate.as_view(),
name='child-update'), name='child-update'),
url(r'children/(?P<pk>[0-9]+)/delete/$', views.ChildDelete.as_view(), url(r'^children/(?P<pk>[0-9]+)/delete/$', views.ChildDelete.as_view(),
name='child-delete'), name='child-delete'),
url(r'children/(?P<slug>[^/.]+)/delete/$', views.ChildDelete.as_view(), url(r'^children/(?P<slug>[^/.]+)/delete/$', views.ChildDelete.as_view(),
name='child-delete'), name='child-delete'),
url(r'changes/$', views.DiaperChangeList.as_view(), url(r'^changes/$', views.DiaperChangeList.as_view(),
name='diaperchange-list'), name='diaperchange-list'),
url(r'changes/add/$', views.DiaperChangeAdd.as_view(), url(r'^changes/add/$', views.DiaperChangeAdd.as_view(),
name='diaperchange-add'), name='diaperchange-add'),
url(r'changes/(?P<pk>[0-9]+)/$', views.DiaperChangeUpdate.as_view(), url(r'^changes/(?P<pk>[0-9]+)/$', views.DiaperChangeUpdate.as_view(),
name='diaperchange-update'), name='diaperchange-update'),
url(r'changes/(?P<pk>[0-9]+)/delete/$', views.DiaperChangeDelete.as_view(), url(r'^changes/(?P<pk>[0-9]+)/delete/$', views.DiaperChangeDelete.as_view(),
name='diaperchange-delete'), name='diaperchange-delete'),
url(r'feedings/$', views.FeedingList.as_view(), name='feeding-list'), url(r'^feedings/$', views.FeedingList.as_view(), name='feeding-list'),
url(r'feedings/add/$', views.FeedingAdd.as_view(), name='feeding-add'), url(r'^feedings/add/$', views.FeedingAdd.as_view(), name='feeding-add'),
url(r'feedings/(?P<pk>[0-9]+)/$', views.FeedingUpdate.as_view(), url(r'^feedings/(?P<pk>[0-9]+)/$', views.FeedingUpdate.as_view(),
name='feeding-update'), name='feeding-update'),
url(r'feedings/(?P<pk>[0-9]+)/delete/$', views.FeedingDelete.as_view(), url(r'^feedings/(?P<pk>[0-9]+)/delete/$', views.FeedingDelete.as_view(),
name='feeding-delete'), name='feeding-delete'),
url(r'notes/$', views.NoteList.as_view(), name='note-list'), url(r'^notes/$', views.NoteList.as_view(), name='note-list'),
url(r'notes/add/$', views.NoteAdd.as_view(), name='note-add'), url(r'^notes/add/$', views.NoteAdd.as_view(), name='note-add'),
url(r'notes/(?P<pk>[0-9]+)/$', views.NoteUpdate.as_view(), url(r'^notes/(?P<pk>[0-9]+)/$', views.NoteUpdate.as_view(),
name='note-update'), name='note-update'),
url(r'notes/(?P<pk>[0-9]+)/delete/$', views.NoteDelete.as_view(), url(r'^notes/(?P<pk>[0-9]+)/delete/$', views.NoteDelete.as_view(),
name='note-delete'), name='note-delete'),
url(r'sleep/$', views.SleepList.as_view(), name='sleep-list'), url(r'^sleep/$', views.SleepList.as_view(), name='sleep-list'),
url(r'sleep/add/$', views.SleepAdd.as_view(), name='sleep-add'), url(r'^sleep/add/$', views.SleepAdd.as_view(), name='sleep-add'),
url(r'sleep/(?P<pk>[0-9]+)/$', views.SleepUpdate.as_view(), url(r'^sleep/(?P<pk>[0-9]+)/$', views.SleepUpdate.as_view(),
name='sleep-update'), name='sleep-update'),
url(r'sleep/(?P<pk>[0-9]+)/delete/$', views.SleepDelete.as_view(), url(r'^sleep/(?P<pk>[0-9]+)/delete/$', views.SleepDelete.as_view(),
name='sleep-delete'), name='sleep-delete'),
url(r'timer/add/$', views.TimerAdd.as_view(), name='timer-add'), url(r'^timer/add/$', views.TimerAdd.as_view(), name='timer-add'),
url(r'timer/add/quick/$', views.TimerAddQuick.as_view(), url(r'^timer/add/quick/$', views.TimerAddQuick.as_view(),
name='timer-add-quick'), name='timer-add-quick'),
url(r'timer/(?P<pk>[0-9]+)/$', views.TimerDetail.as_view(), url(r'^timer/(?P<pk>[0-9]+)/$', views.TimerDetail.as_view(),
name='timer-detail'), name='timer-detail'),
url(r'timer/(?P<pk>[0-9]+)/delete/$', views.TimerDelete.as_view(), url(r'^timer/(?P<pk>[0-9]+)/delete/$', views.TimerDelete.as_view(),
name='timer-delete'), name='timer-delete'),
url(r'tummy-time/$', views.TummyTimeList.as_view(), name='tummytime-list'), url(r'^tummy-time/$', views.TummyTimeList.as_view(), name='tummytime-list'),
url(r'tummy-time/add/$', views.TummyTimeAdd.as_view(), url(r'^tummy-time/add/$', views.TummyTimeAdd.as_view(),
name='tummytime-add'), name='tummytime-add'),
url(r'tummy-time/(?P<pk>[0-9]+)/$', views.TummyTimeUpdate.as_view(), url(r'^tummy-time/(?P<pk>[0-9]+)/$', views.TummyTimeUpdate.as_view(),
name='tummytime-update'), name='tummytime-update'),
url(r'tummy-time/(?P<pk>[0-9]+)/delete/$', views.TummyTimeDelete.as_view(), url(r'^tummy-time/(?P<pk>[0-9]+)/delete/$', views.TummyTimeDelete.as_view(),
name='tummytime-delete'), name='tummytime-delete'),
] ]

View File

@ -8,6 +8,6 @@ from . import views
urlpatterns = [ urlpatterns = [
url(r'^$', views.DashboardRedirect.as_view(), name='dashboard'), url(r'^$', views.DashboardRedirect.as_view(), name='dashboard'),
url(r'^dashboard/$', views.Dashboard.as_view(), name='dashboard-all'), url(r'^dashboard/$', views.Dashboard.as_view(), name='dashboard-all'),
url(r'children/(?P<slug>[^/.]+)/dashboard/$', url(r'^children/(?P<slug>[^/.]+)/dashboard/$',
views.ChildDashboard.as_view(), name='dashboard-child'), views.ChildDashboard.as_view(), name='dashboard-child'),
] ]