If I override a field in an Admin form to limit the selected choices,
e.g.

class MyForm(forms.ModelForm):
    entity =
forms.ModelChoiceField(queryset=MyEntity.objects.all().filter(some_field
="some_value")
    class Meta:
        model = MyEntity

I see that my dropdown in the Form is properly filtered.

However, the search/list admin screen is not. If I use list_editable
in the Admin, the dropdown displays all the items and does not respect
my filter from the form.

How can I fix that? How can I customize the search/list screen, the
same way one customizes the form?

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

Reply via email to