Thankyou - saves me searching down this dead end...

Cheers,

Guy

On Dec 10, 7:54 am, "Alex Koshelev" <[EMAIL PROTECTED]> wrote:
> There is no way to have per-instance limit_choices_to.
>
> On Wed, Dec 10, 2008 at 03:56, GuyBowden <[EMAIL PROTECTED]> wrote:
>
> > Hi,
>
> > I've looked about but can't find the answer to this.
>
> > I'd like to set the limit_choices_to value of a ForeignKey field based
> > on another selection in the current instance.
>
> > i.e. - filter the choices based on another field of the same instance.
>
> > something like this:
>
> > my_fk.limit_choices_to = my_fk.objects.get(Q(type = self.fk_type))
>
> > but that fails as self is not defined by then obviously...
>
> > Thanks
>
>
--~--~---------~--~----~------------~-------~--~----~
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