Skip to content
This repository has been archived by the owner on Jan 5, 2018. It is now read-only.

Issue #2671914: Implement EB configuration UI #25

Open
wants to merge 2 commits into
base: 8.x-1.x
Choose a base branch
from

Conversation

primsi
Copy link
Contributor

@primsi primsi commented Feb 19, 2016

No description provided.

public function buildConfigurationForm(array $form, FormStateInterface $form_state) {
$configuration = $this->getConfiguration();
$settings = $configuration['settings'];
$form += parent::buildConfigurationForm($form, $form_state);
Copy link
Member

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';
}
}
Copy link
Contributor

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.

Copy link
Member

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

@primsi primsi force-pushed the 2671914_conf_ui branch 3 times, most recently from 523c740 to 5c712e7 Compare April 29, 2016 13:24
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
3 participants