public function validateOptionsForm(&
$form, FormStateInterface
$form_state) { parent::
validateOptionsForm($form,
$form_state);
$selected_actions =
$form_state->
getValue(['options', 'selected_actions'
]);
$form_state->
setValue(['options', 'selected_actions'
],
array_values(array_filter($selected_actions)));
} /**
* {@inheritdoc}
*/
public function preRender(&
$values) { parent::
preRender($values);
// If the view is using a table style, provide a placeholder for a
// "select all" checkbox.
if (!
empty($this->view->style_plugin
) &&
$this->view->style_plugin instanceof Table
) { // Add the tableselect css classes.
$this->options
['element_label_class'
] .= 'select-all';
// Hide the actual label of the field on the table header.
$this->options
['label'
] = '';
} }