X-Git-Url: http://www.aleph1.co.uk/gitweb/?a=blobdiff_plain;f=web%2Fmodules%2Fcontrib%2Fentity_browser%2Fsrc%2FPluginConfigurationFormTrait.php;fp=web%2Fmodules%2Fcontrib%2Fentity_browser%2Fsrc%2FPluginConfigurationFormTrait.php;h=312c05a992f80926631430c3860b097aab2eaad0;hb=a2bd1bf0c2c1f1a17d188f4dc0726a45494cefae;hp=0000000000000000000000000000000000000000;hpb=57c063afa3f66b07c4bbddc2d6129a96d90f0aad;p=yaffs-website diff --git a/web/modules/contrib/entity_browser/src/PluginConfigurationFormTrait.php b/web/modules/contrib/entity_browser/src/PluginConfigurationFormTrait.php new file mode 100644 index 000000000..312c05a99 --- /dev/null +++ b/web/modules/contrib/entity_browser/src/PluginConfigurationFormTrait.php @@ -0,0 +1,47 @@ +getValues(); + + if ($this instanceof WidgetInterface) { + $values = $values['table'][$this->uuid()]['form']; + } + + if (!empty($values)) { + foreach ($values as $key => $value) { + if (array_key_exists($key, $this->configuration)) { + $this->configuration[$key] = $value; + } + } + } + } + +}