public function CustomerProfile::validateInlineForm in Commerce Core 8.2
Validates the inline form.
Parameters
array $inline_form: The inline form, containing the following basic properties:
- #parents: Identifies the location of the field values in $form_state.
\Drupal\Core\Form\FormStateInterface $form_state: The form state of the complete form.
Overrides InlineFormBase::validateInlineForm
File
- modules/
order/ src/ Plugin/ Commerce/ InlineForm/ CustomerProfile.php, line 330
Class
- CustomerProfile
- Provides an inline form for managing a customer profile.
Namespace
Drupal\commerce_order\Plugin\Commerce\InlineFormCode
public function validateInlineForm(array &$inline_form, FormStateInterface $form_state) {
parent::validateInlineForm($inline_form, $form_state);
if (!isset($inline_form['rendered'])) {
$form_display = $this
->loadFormDisplay();
$form_display
->extractFormValues($this->entity, $inline_form, $form_state);
$form_display
->validateFormValues($this->entity, $inline_form, $form_state);
}
}