-
Notifications
You must be signed in to change notification settings - Fork 318
Closed
Description
I want to use ModelSelect2Widget with ModelChoiceField. I set queryset to ModelChoiceField, so I don't want to add the same queryset to ModelSelect2Widget. ModelSelect2Widget can take it from self.choices.queryset(related pull request #509). Example how do I use it:
item = forms.ModelChoiceField(queryset=MyModel.objects.filter(is_active=True), required=False, widget=ModelSelect2Widget)
Metadata
Metadata
Assignees
Labels
No labels