The configuration schema for datetime doesn't describe the field properties the way other field types do.

Created on 19 May 2020, about 5 years ago
Updated 6 September 2024, 9 months ago

Most field types in core have configuration schema to describe the properties, and the mapping matches with the properties.

- field.value.string (value)
- field.value.link (title, uri, options)
- field.value.string_long (value)
- field.value.text (value, format)

etc.

The datetime and daterange schema definitions however don't follow this pattern.

field.value.datetime:
  type: mapping
  label: 'Default value'
  mapping:
    default_date_type:
      type: string
      label: 'Default date type'
    default_date:
      type: string
      label: 'Default date value'

I'm wondering whether this is by design or is there something missing still?

I'm asking this because the Conditional Fields module is trying to use the schema of the field type to set the conditions of a field. See https://www.drupal.org/project/conditional_fields/issues/3137764 β†’

It seems that we can use most of the field types but the datetime field we cannot use because of missing description of properties.

Thank you

πŸ’¬ Support request
Status

Closed: works as designed

Version

11.0 πŸ”₯

Component
DatetimeΒ  β†’

Last updated 7 days ago

Created by

πŸ‡ͺπŸ‡ΈSpain nuez Madrid, Spain

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024