You are here

public function Table::wizardSubmit in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 core/modules/views/src/Plugin/views/style/Table.php \Drupal\views\Plugin\views\style\Table::wizardSubmit()

Alter the options of a display before they are added to the view.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

\Drupal\views\Plugin\views\wizard\WizardInterface $wizard: The current used wizard.

array $display_options: The options which will be used on the view. The style plugin should alter this to its own needs.

string $display_type: The display type, either block or page.

Overrides StylePluginBase::wizardSubmit

File

core/modules/views/src/Plugin/views/style/Table.php, line 421
Contains \Drupal\views\Plugin\views\style\Table.

Class

Table
Style plugin to render each item as a row in a table.

Namespace

Drupal\views\Plugin\views\style

Code

public function wizardSubmit(&$form, FormStateInterface $form_state, WizardInterface $wizard, &$display_options, $display_type) {

  // If any of the displays use the table style, make sure that the fields
  // always have a labels by unsetting the override.
  foreach ($display_options['default']['fields'] as &$field) {
    unset($field['label']);
  }
}