2013-03-28 00:23:59 +08:00
|
|
|
"""
|
|
|
|
Test URLs for auth admins.
|
|
|
|
"""
|
|
|
|
|
2015-05-28 23:25:52 +08:00
|
|
|
from django.conf.urls import url
|
2013-03-28 00:23:59 +08:00
|
|
|
from django.contrib import admin
|
2015-01-28 20:35:27 +08:00
|
|
|
from django.contrib.auth.admin import GroupAdmin, UserAdmin
|
|
|
|
from django.contrib.auth.models import Group, User
|
2013-03-28 00:23:59 +08:00
|
|
|
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)
|
|
|
|
|
2014-04-02 08:46:34 +08:00
|
|
|
urlpatterns += [
|
2015-05-28 23:25:52 +08:00
|
|
|
url(r'^admin/', site.urls),
|
2014-04-02 08:46:34 +08:00
|
|
|
]
|