public function LearningPathCreateClassForm::validateForm in Opigno Learning path 8
Same name and namespace in other branches
- 3.x src/Form/LearningPathCreateClassForm.php \Drupal\opigno_learning_path\Form\LearningPathCreateClassForm::validateForm()
Form validation handler.
Parameters
array $form: An associative array containing the structure of the form.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
Overrides FormBase::validateForm
File
- src/
Form/ LearningPathCreateClassForm.php, line 113
Class
- LearningPathCreateClassForm
- Members create form.
Namespace
Drupal\opigno_learning_path\FormCode
public function validateForm(array &$form, FormStateInterface $form_state) {
if (empty($form_state
->getValue('new_class_users'))) {
$form_state->hasValidateError = TRUE;
}
}