On Aug 25, 2:57 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
wrote:
> > Kinda related, I've always wished for a way to set a default for an
> > admin list_filter. So there's something cool for you to do :)
>
> You want to elaborate on a default for list_filter?

Sure. When you visit the admin list page for an object type, you get
the list_filter options at the side. What would be cool is if it was
possible to somehow specify a default value, rather than "all".

For example, say we (hypothetically) wanted to show only staff members
on their user page by default.
http://www.djangoproject.com/documentation/model-api/#list-filter

Perhaps by adding something like the following to the model's Admin
class:
list_filter_defaults = {'is_staff': True}


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-developers@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to