diff options
| author | Étienne Loks <etienne.loks@proxience.com> | 2014-05-12 17:56:38 +0200 | 
|---|---|---|
| committer | Étienne Loks <etienne.loks@proxience.com> | 2014-05-12 17:56:38 +0200 | 
| commit | d7b838f3c088337248c0c94d9b765b68e30551a8 (patch) | |
| tree | 6a6be2f86868d45565c83a47753bbfe182383689 /ishtar_common/forms_common.py | |
| parent | 7d8bfcc053c9d3448e405f90df6eff214ac7d2e3 (diff) | |
| download | Ishtar-d7b838f3c088337248c0c94d9b765b68e30551a8.tar.bz2 Ishtar-d7b838f3c088337248c0c94d9b765b68e30551a8.zip | |
Add email field to organizations - Django management of email fields (refs #1677)
Diffstat (limited to 'ishtar_common/forms_common.py')
| -rw-r--r-- | ishtar_common/forms_common.py | 9 | 
1 files changed, 6 insertions, 3 deletions
| diff --git a/ishtar_common/forms_common.py b/ishtar_common/forms_common.py index 790a128c7..0bea551cf 100644 --- a/ishtar_common/forms_common.py +++ b/ishtar_common/forms_common.py @@ -82,6 +82,7 @@ class OrganizationForm(forms.Form):      town = forms.CharField(label=_(u"Town"), max_length=30, required=False)      country = forms.CharField(label=_(u"Country"), max_length=30,                                required=False) +    email = forms.EmailField(label=_(u"Email"), required=False)      phone = forms.CharField(label=_(u"Phone"), max_length=18, required=False)      mobile_phone = forms.CharField(label=_(u"Town"), max_length=18,                                     required=False) @@ -123,7 +124,7 @@ class OrganizationFormSelection(forms.Form):  class PersonSelect(TableSelect):      name = forms.CharField(label=_(u"Name"), max_length=30)      surname = forms.CharField(label=_(u"Surname"), max_length=20) -    email = forms.CharField(label=_(u"Email"), max_length=40) +    email = forms.CharField(label=_(u"Email"), max_length=75)      person_types = forms.ChoiceField(label=_(u"Type"), choices=[])      attached_to = forms.IntegerField(label=_("Organization"),           widget=widgets.JQueryAutoComplete( @@ -161,8 +162,10 @@ class SimplePersonForm(forms.Form):      town = forms.CharField(label=_(u"Town"), max_length=30, required=False)      country = forms.CharField(label=_(u"Country"), max_length=30,                                required=False) -    email = forms.CharField(label=_(u"Email"), max_length=40, required=False, -                            validators=[validators.validate_email]) +    email = forms.EmailField(label=_(u"Email"), required=False) +    phone = forms.CharField(label=_(u"Phone"), max_length=18, required=False) +    mobile_phone = forms.CharField(label=_(u"Town"), max_length=18, +                                   required=False)      attached_to = forms.IntegerField(label=_("Current organization"),          widget=widgets.JQueryAutoComplete(                      reverse_lazy('autocomplete-organization'), | 
