- Issue created by @mlncn
- ๐บ๐ธUnited States mlncn Minneapolis, MN, USA
This is true whether "Select List" or "Select List (Cardinality)" is chosen for the widget.
- ๐บ๐ธUnited States mlncn Minneapolis, MN, USA
Possibly relevantโ i am on Drupal 11. (Courtesy of ๐ Automated Drupal 11 compatibility fixes for field_config_cardinality Active )
- Merge request !14Set multiple to false only if field config cardinality is one โ (Closed) created by mlncn
- ๐บ๐ธUnited States mlncn Minneapolis, MN, USA
This simple logic change fixes my problem.
In
field_config_cardinality_field_widget_complete_form_alter
the// Implementation for multi select type.
had$cardinality_config >= 1
as the check to setting$elements['#multiple'] = FALSE;
and my merge request here changes that to check that the cardinality equals one, which seems to make sense.My only problem with this fix is that i cannot believe no one reported the problem for seven years, so i feel like i must be missing something?
- Status changed to Needs work
about 1 month ago 8:01pm 3 July 2025 - First commit to issue fork.
- ๐บ๐ธUnited States smustgrave
Almost the entire issue queue seems to be bugs and probably because it lacks test coverage. I'm working on adding some basic coverage so we can wait on those are start new ones too
- ๐บ๐ธUnited States smustgrave
Also find that widget doesn't actually limit anything.
- ๐บ๐ธUnited States smustgrave
maybe we need a follow up for why this plugin is needed but this does fix the issue for regular selects, added test coverage.
Automatically closed - issue fixed for 2 weeks with no activity.