Re: Returning template data from a ManyToMany model

2012-04-18 Thread LJ
Thank you, Daniel. That makes sense now. If the full objects are already there, then this should work great! L J On Apr 17, 4:07 am, Daniel Roseman wrote: > On Tuesday, 17 April 2012 07:10:35 UTC+1, LJ wrote: > > > I am having trouble figuring out how to query the database

Re: Returning template data from a ManyToMany model

2012-04-18 Thread LJ
Thank you, Phang. I was not familiar with the locals() method, so I may look into this. L J On Apr 17, 2:22 am, Phang Mulianto wrote: > On Tue, Apr 17, 2012 at 2:10 PM, LJ wrote: > > I am having trouble figuring out how to query the database and return

Re: Returning template data from a ManyToMany model

2012-04-17 Thread Daniel Roseman
On Tuesday, 17 April 2012 07:10:35 UTC+1, LJ wrote: > > I am having trouble figuring out how to query the database and return > the results in a format that my template can render appropriately. > I have a model that has a ManyToMany field: > > class Student() > ... > parents =

Re: Returning template data from a ManyToMany model

2012-04-17 Thread Phang Mulianto
On Tue, Apr 17, 2012 at 2:10 PM, LJ wrote: > I am having trouble figuring out how to query the database and return > the results in a format that my template can render appropriately. > I have a model that has a ManyToMany field: > > class Student() > ... > parents =

Returning template data from a ManyToMany model

2012-04-17 Thread LJ
I am having trouble figuring out how to query the database and return the results in a format that my template can render appropriately. I have a model that has a ManyToMany field: class Student() ... parents = models.ManyToManyField('parents.Parent', blank=True, null=True) ... The