Django Modelform Save() Method Issue
I have a model form: class SnippetForm(ModelForm): class Meta: model = Snippet exclude = ['author', 'slug'] and I want to be able to edit a particular instanc
Solution 1:
I don't see why it would happen. What version of django is it?
In any case, you can manually force update passing the corresponding argument.
form = SnippetForm(data=request.POST, instance=snippet, force_update=True)
Post a Comment for "Django Modelform Save() Method Issue"