- November 18, 2009
- admin changelist
- 0 (after 0 ratings)
By default, a "Show all" link will appear in the changelist pager only if fewer than 200 records are in the result. Since it is rare that there will be more than one page of records yet fewer than 200, the "Show all" link almost never shows up. Pasting this code somewhere in your app will allow you to increase the 200-record maximum.
"Show all" is very handy when used in combination with batch actions and filters, and this change will enable it for most situations. Note that this allows a changelist with up to 10,000 results, which results in a lot of HTML that can tax slower browsers and older machines. For me, it has been worth the tradeoff, since my users have fast enough computers and need to be able to make batch changes efficiently.
1 2 3
# Increase maximum number of changelist items for "Show all" link to appear. from django.contrib.admin.views import main as admin_views_main admin_views_main.MAX_SHOW_ALL_ALLOWED = 10000
More like this
- Group results by a range of values in admin sidebar by wgollino 8 years, 3 months ago
- Image resize on demand by VidJa 7 years, 5 months ago
- Dump a model instance and related objects as a Python data structure by akaihola 4 years, 3 months ago
- Generic CSV Export by zbyte64 7 years, 11 months ago
- Button Admin by delfick 6 years, 5 months ago