Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 292327

Support multiple implementations for hook_field_widget_third_party_settings_form

$
0
0

Problem/Motivation

Since the flood gates are open for multiple implementations of the same hook in the same modules, the hook field_widget_third_party_settings_form doesn't support that since it expects each module to have only one implementation

Steps to reproduce

Use the Hook attribute twice in the same module

#[Hook('field_widget_third_party_settings_form')]                                                                                                                                                             
  public function fieldWidgetThirdPartySettingsForm(WidgetInterface $plugin, FieldDefinitionInterface $field_definition, $form_mode, $form, FormStateInterface $form_state) {

adding different form elements.

Proposed resolution

Merge all elements of the same module in the same form array

Remaining tasks

Code solutions
Add tests

User interface changes

None


Viewing all articles
Browse latest Browse all 292327

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>