Re: One to many mixins?

2009-12-11 Thread Preston Holmes
On Dec 10, 5:53 am, Shai wrote: > Hi all, > > I'm not sure my title is correct. Here Is my problem: I want to use > the django admin for data entry into some models. The models are based > on actual paper forms. There are several forms. and they share some > fields. I would like to follow the pr

Re: One to many mixins?

2009-12-11 Thread Shai
Thanks for the reply, but that would force me to link each SubForm1 object with both a Form1 & Form2 object. I would like to link them with either Form1 or Form2 Shai On Dec 10, 5:22 pm, Superman wrote: > Can you not create another Field in SubForm 1 model? Like so: > > class SubForm1(models.Mod

Re: One to many mixins?

2009-12-10 Thread Superman
Can you not create another Field in SubForm 1 model? Like so: class SubForm1(models.Model): def __unicode__(self): return "SubForm1" Form1 = models.ForeignKey(Form1) Form2 = models.ForeignKey(Form2) ## some fields here On Dec 10, 8:53 am, Shai wrote: > Hi all, > > I'm not sure my t

One to many mixins?

2009-12-10 Thread Shai
Hi all, I'm not sure my title is correct. Here Is my problem: I want to use the django admin for data entry into some models. The models are based on actual paper forms. There are several forms. and they share some fields. I would like to follow the principle of DRY when creating this app. As an i