public static function InlineFormBase::updatePageTitle in Commerce Core 8.2
Updates the page title based on the inline form's #page_title property.
Parameters
array $inline_form: The inline form.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
array $complete_form: The complete form structure.
Return value
array The form element.
File
- src/
Plugin/ Commerce/ InlineForm/ InlineFormBase.php, line 174
Class
- InlineFormBase
- Provides the base class for inline forms.
Namespace
Drupal\commerce\Plugin\Commerce\InlineFormCode
public static function updatePageTitle(array &$inline_form, FormStateInterface $form_state, array &$complete_form) {
if (!empty($inline_form['#page_title'])) {
$complete_form['#title'] = $inline_form['#page_title'];
}
return $inline_form;
}