Opened 18 years ago

Closed 18 years ago

#4206 closed (duplicate)

In Admin "list_filter" does not respect "limit_choices_to"

Reported by: david@… Owned by: Adrian Holovaty
Component: contrib.admin Version: dev
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

If a list filter is defined as

    list_filter = ('nl_group')

And the 'nl_group' field is defined as

  nl_group = models.ForeignKey('self', limit_choices_to = {'o1type__exact': 'NL'}, null=True, blank=True)

Then the list filter will show ALL distinct values of 'self' rather than the distinct values in 'self' that have oltype='NL'

Change History (1)

comment:1 by Jeremy Dunck, 18 years ago

Resolution: duplicate
Status: newclosed

This is a duplicate of #3096

Note: See TracTickets for help on using tickets.
Back to Top