If you want to add extra attributes when saving a ModelForm, you can save the form with commit=False
. I commonly use this to set a foreign key field for example.
if form.is_valid() # some Django ModelForm object
bite = form.save(commit=False)
bite.user = request.user # set the user foreign key field
bite.save()
#Django