On 8/22/07, sean <[EMAIL PROTECTED]> wrote:
> for  i in requested_forms:
>     form=mediaform(data, auto_id="some_generated_id")
>     # assign the queryset to the choices
>     form.base_fields['somefield'].queryset = qs

Try adding:
      form.base_fields['somefield'].widget.choices =
form.base_fields['somefield'].choices

after modifying the queryset of a ModelChoiceField.  The widget has a
copy of the original QuerySetIterator that points to the old QuerySet,
so you have to give it an updated copy.
http://fenron.blogspot.com/2007/06/setting-custom-queryset-for.html

  Bill

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@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-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to