Skip to content
Snippets Groups Projects
Commit 33737e44 authored by Ana Pettirossi's avatar Ana Pettirossi
Browse files

Issue #6 - Fix 'options' not listing predefined values

parent 2d419d19
No related branches found
No related tags found
No related merge requests found
......@@ -49,6 +49,12 @@ class WebformElementOptions extends FieldPluginBase {
WebformEntitySelect::setOptions($value);
}
}
else {
// Handle predefined options.
if (is_string($value['#options']) && $value['plugin'] instanceof Select) {
$value['#options'] = WebformOptions::getElementOptions($value);
}
}
foreach ($value['#options'] as $value => $title) {
$response['title'] = $title;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment