function EntityField::blockSubmit

Same name in other branches
  1. 4.0.x modules/ctools_block/src/Plugin/Block/EntityField.php \Drupal\ctools_block\Plugin\Block\EntityField::blockSubmit()

Overrides BlockPluginTrait::blockSubmit

File

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

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');
}