I've made a model with foreign keys in order to save some typing, and I think it also looks cleaner this way:
class Model_Sub( models.Model ):
some_fields
class Model_Main( models.Model ):
field_1 = models.ForeignKey( Model_Sub, related_name="sub_field_1" )
field_2 = models.ForeignKey( Model_Sub, related_name="sub_field_2" )
But when I want my users to submit the form, I want new instances of the sub model, not from a query set. I want the Model_Sub to be seamlessly included with the main model as a form. Is there anyway to achieve this using ModelForm?
Thanks for the help
David
Model_Suma summing function, or are you referring toModel_Sub? - Cole