Browse Source

Fix #2101 (#2102)

pull/2110/head
Victor Fabre 7 years ago
committed by Edward
parent
commit
1c8394bd3f
  1. 6
      sapl/audiencia/forms.py

6
sapl/audiencia/forms.py

@ -77,9 +77,11 @@ class AudienciaForm(forms.ModelForm):
msg = _('A hora de fim não pode ser anterior a hora de ínicio')
raise ValidationError(msg)
return self.cleaned_data
return cleaned_data
@transaction.atomic()
def save(self, commit=True):
audiencia = super(AudienciaForm, self).save(commit)
audiencia = super(AudienciaForm, self).save(False)
audiencia.materia = self.cleaned_data['materia']
audiencia.save()
return audiencia
Loading…
Cancel
Save