2013-03-28 00:23:59 +08:00
|
|
|
"""
|
|
|
|
Test URLs for auth admins.
|
|
|
|
"""
|
|
|
|
|
|
|
|
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
|
2018-12-08 06:52:28 +08:00
|
|
|
from django.urls import path
|
2013-03-28 00:23:59 +08:00
|
|
|
|
|
|
|
# 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 += [
|
2018-12-08 06:52:28 +08:00
|
|
|
path('admin/', site.urls),
|
2014-04-02 08:46:34 +08:00
|
|
|
]
|