mirror of
https://github.com/django/django.git
synced 2024-12-23 09:36:06 +00:00
1e82094f1b
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.
19 lines
487 B
Python
19 lines
487 B
Python
"""
|
|
Test URLs for auth admins.
|
|
"""
|
|
|
|
from django.conf.urls import url
|
|
from django.contrib import admin
|
|
from django.contrib.auth.admin import GroupAdmin, UserAdmin
|
|
from django.contrib.auth.models import Group, User
|
|
from django.contrib.auth.urls import urlpatterns
|
|
|
|
# Create a silo'd admin site for just the user/group admins.
|
|
site = admin.AdminSite(name='auth_test_admin')
|
|
site.register(User, UserAdmin)
|
|
site.register(Group, GroupAdmin)
|
|
|
|
urlpatterns += [
|
|
url(r'^admin/', site.urls),
|
|
]
|