Ignore disabled FormWidgets in getSaveData() (#4116)
Fixes #3983. Credit to @tmus.
This commit is contained in:
parent
5c15687032
commit
40bc6e0d67
|
|
@ -1182,6 +1182,11 @@ class Form extends WidgetBase
|
|||
foreach ($this->formWidgets as $field => $widget) {
|
||||
$parts = HtmlHelper::nameToArray($field);
|
||||
|
||||
if ((isset($widget->config->disabled) && $widget->config->disabled)
|
||||
|| (isset($widget->config->hidden) && $widget->config->hidden)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$widgetValue = $widget->getSaveValue($this->dataArrayGet($result, $parts));
|
||||
$this->dataArraySet($result, $parts, $widgetValue);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue