summaryrefslogtreecommitdiff
path: root/archaeological_operations/forms.py
diff options
context:
space:
mode:
Diffstat (limited to 'archaeological_operations/forms.py')
-rw-r--r--archaeological_operations/forms.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/archaeological_operations/forms.py b/archaeological_operations/forms.py
index 2852db79f..d0e4be0d3 100644
--- a/archaeological_operations/forms.py
+++ b/archaeological_operations/forms.py
@@ -98,9 +98,10 @@ class ParcelForm(forms.Form):
if not self.cleaned_data or (DELETION_FIELD_NAME in self.cleaned_data \
and self.cleaned_data[DELETION_FIELD_NAME]):
return
- if not self.cleaned_data.get('parcel_number'):
+ if not self.cleaned_data.get('parcel_number') and \
+ self.cleaned_data.get('section') != 'DP':
return {}
- for key in ('town', 'parcel_number', 'section'):
+ for key in ('town', 'section'):
if not key in self.cleaned_data or not self.cleaned_data[key]:
raise forms.ValidationError(_(u"Town section and parcel number "
u"fields are required."))