From 20c05b5c71ba6df1e37466b2b4a8623d5ebac556 Mon Sep 17 00:00:00 2001 From: catch <catch@35733.no-reply.drupal.org> Date: Mon, 11 Dec 2023 10:52:21 +0000 Subject: [PATCH] Issue #3401464 by anushrikumari, sime, shweta__sharma, lauriii, ankithashetty, sijumpk, rkoller: Date range should be in the date_time category --- .../src/Plugin/Field/FieldType/DateRangeItem.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/core/modules/datetime_range/src/Plugin/Field/FieldType/DateRangeItem.php b/core/modules/datetime_range/src/Plugin/Field/FieldType/DateRangeItem.php index 7c34ed127c02..a9fd662bc240 100644 --- a/core/modules/datetime_range/src/Plugin/Field/FieldType/DateRangeItem.php +++ b/core/modules/datetime_range/src/Plugin/Field/FieldType/DateRangeItem.php @@ -16,7 +16,12 @@ * @FieldType( * id = "daterange", * label = @Translation("Date range"), - * description = @Translation("Create and store date ranges."), + * category = "date_time", + * description = { + * @Translation("Ideal for storing durations that consist of start and end dates (and times)"), + * @Translation("Choose between setting both date and time, or date only, for each duration"), + * @Translation("The system automatically validates that the end date (and time) is later than the start, and both fields are completed"), + * }, * default_widget = "daterange_default", * default_formatter = "daterange_default", * list_class = "\Drupal\datetime_range\Plugin\Field\FieldType\DateRangeFieldItemList" -- GitLab