From d5891f62d082aa668a2480120c73c5a7589af6eb Mon Sep 17 00:00:00 2001 From: LeandroRoberto Date: Thu, 3 Nov 2016 16:53:21 -0200 Subject: [PATCH] Corrige method save do form NormaJuridicaForm --- sapl/norma/forms.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sapl/norma/forms.py b/sapl/norma/forms.py index 77e9604a4..4fd8c8579 100644 --- a/sapl/norma/forms.py +++ b/sapl/norma/forms.py @@ -190,8 +190,8 @@ class NormaJuridicaForm(ModelForm): return texto_integral def save(self, commit=False): - norma = super(NormaJuridicaForm, self).save(commit) + norma = self.instance norma.timestamp = datetime.now() norma.materia = self.cleaned_data['materia'] - norma.save() + norma = super(NormaJuridicaForm, self).save(commit=True) return norma