Re: Filtering by the intermediary table using the GET parameters

2010-02-03 Thread Eugene Mirotin
Thanks! Adding the m2m field helped, and the address was simply /product/? has_standard="pk" On Feb 3, 12:42 am, Woongcheol Yang wrote: > Let's say your model looks like the following: > > class Standard(models.Model): > > class Product(models.Model): >     has_standard = models.ManyToManyField(

Re: Filtering by the intermediary table using the GET parameters

2010-02-02 Thread Woongcheol Yang
Let's say your model looks like the following: class Standard(models.Model): class Product(models.Model): has_standard = models.ManyToManyField(Standard, through="ProductStandard") class ProductStandard(models.Model): standard = models.ForeignKey(Standard) product = models.ForeignKey

Filtering by the intermediary table using the GET parameters

2010-02-02 Thread Eugene Mirotin
I have 3 models - Standard, Product, and ProductStandard. Standards represents some standardization document. Product represents some product. ProductStandard is the intermediary table having 2 FKs (Standard and Product) as well as some extra fields (like comments about the Standard for the specif