agenda: check if duration is an integer in new appointment form
Closes #5086
This commit is contained in:
parent
74d4a9e238
commit
7a2d7c8a9c
|
@ -65,7 +65,7 @@ class NewAppointmentForm(BaseForm):
|
|||
try:
|
||||
return int(duration)
|
||||
except ValueError:
|
||||
return 0
|
||||
raise forms.ValidationError('Veuillez saisir un entier')
|
||||
|
||||
def clean_patient(self):
|
||||
patients = self.cleaned_data['patient']
|
||||
|
|
Reference in New Issue