mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Fixed #21927 -- Made application and instance namespaces more distinct.
Made URL application namespaces be set in the included URLconf and instance namespaces in the call to include(). Deprecated other ways to set application and instance namespaces.
This commit is contained in:
committed by
Tim Graham
parent
39937de7e6
commit
1e82094f1b
16
tests/urlpatterns_reverse/included_app_urls.py
Normal file
16
tests/urlpatterns_reverse/included_app_urls.py
Normal file
@@ -0,0 +1,16 @@
|
||||
from django.conf.urls import url
|
||||
|
||||
from . import views
|
||||
|
||||
app_name = 'inc-app'
|
||||
urlpatterns = [
|
||||
url(r'^normal/$', views.empty_view, name='inc-normal-view'),
|
||||
url(r'^normal/(?P<arg1>[0-9]+)/(?P<arg2>[0-9]+)/$', views.empty_view, name='inc-normal-view'),
|
||||
|
||||
url(r'^\+\\\$\*/$', views.empty_view, name='inc-special-view'),
|
||||
|
||||
url(r'^mixed_args/([0-9]+)/(?P<arg2>[0-9]+)/$', views.empty_view, name='inc-mixed-args'),
|
||||
url(r'^no_kwargs/([0-9]+)/([0-9]+)/$', views.empty_view, name='inc-no-kwargs'),
|
||||
|
||||
url(r'^view_class/(?P<arg1>[0-9]+)/(?P<arg2>[0-9]+)/$', views.view_class_instance, name='inc-view-class'),
|
||||
]
|
||||
Reference in New Issue
Block a user