On Jul 14, 2009, at 10:35 AM, Jonathan Buchanan wrote:
>
> One option would be to use a generic relation:
>
> http://docs.djangoproject.com/en/dev/ref/contrib/contenttypes/#id1
>
> Regards,
> Jonathan.
>
>
Yes, this is probably the right way to do it. I had heard about
generic relation, but
2009/7/14 The Danny Bos :
>
> Hey there, this may not be appropriate, but I'm building in Django so
> here goes ...
>
> I'm creating an Interviews app/table in my Django 'Books' (test)
> project. Just wrapping my head around it before I start on my music
> based website ... Anyway,
>
> For my 'Int
On Jul 14, 2009, at 9:23 AM, The Danny Bos wrote:
>
>
> So the Author and Illustrator tables would stay as is.
> How would the Interview table talk to both of those tables at once, to
> allow me to assign an interview to who I'm interviewing. Whether it's
> an Illustrator, Author or even down th
So the Author and Illustrator tables would stay as is.
How would the Interview table talk to both of those tables at once, to
allow me to assign an interview to who I'm interviewing. Whether it's
an Illustrator, Author or even down the track a Publisher.
Like so?
class Interview(models.Model):
I think you'd just have the interview table without any foreign keys,
then add a ManyToMany to each of your Author and Illustrator models.
You would still, of course, be able to start with your interview table
and get the authors or illustrators, if necessary in your app. It
might be handy
Hey there, this may not be appropriate, but I'm building in Django so
here goes ...
I'm creating an Interviews app/table in my Django 'Books' (test)
project. Just wrapping my head around it before I start on my music
based website ... Anyway,
For my 'Interview' table, how would I assign an inter
6 matches
Mail list logo