-
Notifications
You must be signed in to change notification settings - Fork 13
Issue #2671914: Implement EB configuration UI #25
base: 8.x-1.x
Are you sure you want to change the base?
Conversation
0db207c
to
32dc164
Compare
public function buildConfigurationForm(array $form, FormStateInterface $form_state) { | ||
$configuration = $this->getConfiguration(); | ||
$settings = $configuration['settings']; | ||
$form += parent::buildConfigurationForm($form, $form_state); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Parent is WidgetBase, which doesn't do anything in buildConfigurationForm(). Only description is added here, but we have few more configuration options in defaultConfiguration(), which we would need to handle.
if (!empty($values['max_filesize'])) { | ||
$this->configuration['max_filesize'] = $values['max_filesize'] . 'M'; | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
None of the other options are mentioned in this method, and in my testing, any changes I made to them were not saved.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might be possible to rely on default submit implementation. See \Drupal\entity_browser\PluginConfigurationFormTrait
523c740
to
5c712e7
Compare
No description provided.