mirror of
https://github.com/django/django.git
synced 2025-10-26 23:26:08 +00:00
newforms-admin: Moved list_per_page from AdminOptions to ModelAdmin.
git-svn-id: http://code.djangoproject.com/svn/django/branches/newforms-admin@4336 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -37,6 +37,7 @@ class ModelAdmin(object):
|
||||
list_display_links = ()
|
||||
list_filter = ()
|
||||
list_select_related = False
|
||||
list_per_page = 100
|
||||
search_fields = ()
|
||||
date_hierarchy = None
|
||||
save_as = False
|
||||
@@ -276,7 +277,7 @@ class ModelAdmin(object):
|
||||
raise PermissionDenied
|
||||
try:
|
||||
cl = ChangeList(request, self.model, self.list_display, self.list_display_links, self.list_filter,
|
||||
self.date_hierarchy, self.search_fields, self.list_select_related)
|
||||
self.date_hierarchy, self.search_fields, self.list_select_related, self.list_per_page)
|
||||
except IncorrectLookupParameters:
|
||||
# Wacky lookup parameters were given, so redirect to the main
|
||||
# changelist page, without parameters, and pass an 'invalid=1'
|
||||
|
||||
Reference in New Issue
Block a user