contacts: mark first and last names as required (#9449)

This commit is contained in:
Frédéric Péters 2015-12-29 18:21:00 +01:00
parent 2810150e3c
commit 7de130d531
1 changed files with 6 additions and 2 deletions

View File

@ -19,8 +19,12 @@ from django.utils.translation import ugettext_lazy as _
class ContactAddForm(forms.Form):
first_name = forms.CharField(label=_('First Name'))
last_name = forms.CharField(label=_('Last Name'))
first_name = forms.CharField(label=_('First Name'),
required=True,
widget=forms.TextInput(attrs={'required': 'required'}))
last_name = forms.CharField(label=_('Last Name'),
required=True,
widget=forms.TextInput(attrs={'required': 'required'}))
email = forms.CharField(label=_('Email'))
address = forms.CharField(label=_('Address'))
zipcode = forms.CharField(label=_('Zip Code'))