Skip to content

Commit

Permalink
Fixes #397 -- Adds custom required message to LocationForm
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverroick committed Jul 19, 2016
1 parent c1275be commit 93bde83
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion cadasta/spatial/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,13 @@


class LocationForm(AttributeModelForm):
geometry = gisforms.GeometryField(widget=LeafletWidget())
geometry = gisforms.GeometryField(
widget=LeafletWidget(),
error_messages={
'required': _('No map location was provided. Please use the tools '
'provided on the left side of the map to mark your '
'new location.')}
)
attributes_field = 'attributes'

class Meta:
Expand Down

0 comments on commit 93bde83

Please sign in to comment.