Re: One from from multiple models using ModelForm

2011-12-06 Thread CrabbyPete
That is to bad. I have a project that I use mongodb and mongotools and I can do the following with one form and it works great. I wonder if any other form tools can do it class UserForm ( MongoForm ): class Meta: document = User fields = ('first_name','last_name') class Profi

Re: One from from multiple models using ModelForm

2011-12-04 Thread akaariai
On Dec 4, 6:05 pm, CrabbyPete wrote: > I wanted to combine two models into one form so I created the > following > > class UserForm( ModelForm ): >     class Meta: >         model = User >         fields = ('email','first_name','last_name') > > class ProfileForm( ModelForm ): >     class Meta: >  

One from from multiple models using ModelForm

2011-12-04 Thread CrabbyPete
I wanted to combine two models into one form so I created the following class UserForm( ModelForm ): class Meta: model = User fields = ('email','first_name','last_name') class ProfileForm( ModelForm ): class Meta: model = Profile class UserProfile ( UserForm, Prof