function WizardPluginBase::validateView
Implements Drupal\views\Plugin\views\wizard\WizardInterface::validate().
Instantiates the view from the form submission and validates its values.
Parameters
array $form: The full wizard form array.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the wizard form.
Return value
array An empty array if the view is valid; an array of error strings if it is not.
Overrides WizardInterface::validateView
File
- 
              core/modules/ views/ src/ Plugin/ views/ wizard/ WizardPluginBase.php, line 1284 
Class
- WizardPluginBase
- Base class for Views wizard plugins.
Namespace
Drupal\views\Plugin\views\wizardCode
public function validateView(array $form, FormStateInterface $form_state) {
  $view = $this->instantiateView($form, $form_state);
  $errors = $view->getExecutable()
    ->validate();
  if (empty($errors)) {
    $this->setValidatedView($form, $form_state, $view);
  }
  return $errors;
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
