diff options
| author | Ramiro Morales <cramm0@gmail.com> | 2012-12-03 20:39:03 -0300 |
|---|---|---|
| committer | Ramiro Morales <cramm0@gmail.com> | 2012-12-04 19:53:52 -0300 |
| commit | 6a098aa6f29b484254de50c4eb113bdbad1d7e78 (patch) | |
| tree | 3e08e1697cf71d99ecfc3827949501af4ea5b511 /tests/regressiontests/admin_views/customadmin.py | |
| parent | b6f67bd50e77b8501a4e90b7a83381412b18fcc7 (diff) | |
[1.5.x] Fixed #18697 -- Made values accepted for two customizable admin templates consistent.
Thanks and at cloverfastfood dot com for the report.
b64d30405a3d5468dc8c6232747d45bbeee4f7bb from master.
Diffstat (limited to 'tests/regressiontests/admin_views/customadmin.py')
| -rw-r--r-- | tests/regressiontests/admin_views/customadmin.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/regressiontests/admin_views/customadmin.py b/tests/regressiontests/admin_views/customadmin.py index 031fb50f0f..d69d690af0 100644 --- a/tests/regressiontests/admin_views/customadmin.py +++ b/tests/regressiontests/admin_views/customadmin.py @@ -16,7 +16,7 @@ class Admin2(admin.AdminSite): login_form = forms.CustomAdminAuthenticationForm login_template = 'custom_admin/login.html' logout_template = 'custom_admin/logout.html' - index_template = 'custom_admin/index.html' + index_template = ['custom_admin/index.html'] # a list, to test fix for #18697 password_change_template = 'custom_admin/password_change_form.html' password_change_done_template = 'custom_admin/password_change_done.html' @@ -40,6 +40,10 @@ class UserLimitedAdmin(UserAdmin): return qs.filter(is_superuser=False) +class CustomPwdTemplateUserAdmin(UserAdmin): + change_user_password_template = ['admin/auth/user/change_password.html'] # a list, to test fix for #18697 + + site = Admin2(name="admin2") site.register(models.Article, base_admin.ArticleAdmin) @@ -50,3 +54,6 @@ site.register(models.ChapterXtra1, base_admin.ChapterXtra1Admin) site.register(User, UserLimitedAdmin) site.register(models.UndeletableObject, base_admin.UndeletableObjectAdmin) site.register(models.Simple, base_admin.AttributeErrorRaisingAdmin) + +simple_site = Admin2(name='admin4') +simple_site.register(User, CustomPwdTemplateUserAdmin) |
