You are here

public function ViewsPhp::validateOptionsForm in Views PHP 8

Same name in this branch
  1. 8 src/Plugin/views/access/ViewsPhp.php \Drupal\views_php\Plugin\views\access\ViewsPhp::validateOptionsForm()
  2. 8 src/Plugin/views/cache/ViewsPhp.php \Drupal\views_php\Plugin\views\cache\ViewsPhp::validateOptionsForm()

Validate the options form.

Overrides PluginBase::validateOptionsForm

File

src/Plugin/views/cache/ViewsPhp.php, line 71
Contains \Drupal\views_php\Plugin\views\cache\ViewsPhp.

Class

ViewsPhp
Caching of query results for Views displays based on custom PHP code.

Namespace

Drupal\views_php\Plugin\views\cache

Code

public function validateOptionsForm(&$form, FormStateInterface $form_state) {
  $options = $form_state
    ->getValue('options');
  $form_state
    ->setValue('cache_options', $options);
}