diff --git a/ckanext/qdes_schema/qdes_ckan_dataset.json b/ckanext/qdes_schema/qdes_ckan_dataset.json index cbbd6b8b..fb470b95 100644 --- a/ckanext/qdes_schema/qdes_ckan_dataset.json +++ b/ckanext/qdes_schema/qdes_ckan_dataset.json @@ -91,7 +91,7 @@ }, { "field_name": "temporal_start", - "label": "Start", + "label": "Temporal coverage start", "display_property": "dcat:startDate", "preset": "date", "validators": "qdes_temporal_start_end_date", @@ -100,7 +100,7 @@ }, { "field_name": "temporal_end", - "label": "End", + "label": "Temporal coverage end", "display_property": "dcat:endDate", "preset": "date", "validators": "qdes_temporal_start_end_date", diff --git a/ckanext/qdes_schema/validators.py b/ckanext/qdes_schema/validators.py index f0873367..eafe46ed 100644 --- a/ckanext/qdes_schema/validators.py +++ b/ckanext/qdes_schema/validators.py @@ -18,6 +18,6 @@ def qdes_temporal_start_end_date(key, flattened_data, errors, context): if (len(temporal_start_value) > 0) and (len(temporal_end_value) > 0): if dt.strptime(temporal_start_value, '%Y-%m-%d') > dt.strptime(temporal_end_value, '%Y-%m-%d'): if key == ('temporal_start',): - raise toolkit.Invalid("Start date must be less then end date.") + raise toolkit.Invalid("Must be earlier than end date.") elif key == ('temporal_end',): - raise toolkit.Invalid("End date must be higher then start date.") + raise toolkit.Invalid("Must be later than start date.")