You are here

public function EntityField::blockSubmit in Chaos Tool Suite (ctools) 8.3

Overrides BlockPluginTrait::blockSubmit

File

modules/ctools_block/src/Plugin/Block/EntityField.php, line 287

Class

EntityField
Provides a block to a field on an entity.

Namespace

Drupal\ctools_block\Plugin\Block

Code

public function blockSubmit($form, FormStateInterface $form_state) {
  $this->configuration['formatter']['label'] = $form_state
    ->getValue('formatter_label');
  $this->configuration['formatter']['type'] = $form_state
    ->getValue('formatter_type');

  // @todo Remove this manual cast after https://www.drupal.org/node/2635236
  //   is resolved.
  $this->configuration['formatter']['settings'] = (array) $form_state
    ->getValue('formatter_settings');
}