You are here

public function FieldInheritanceAjaxForm::buildForm in Field Inheritance 8

Same name and namespace in other branches
  1. 2.0.x src/Form/FieldInheritanceAjaxForm.php \Drupal\field_inheritance\Form\FieldInheritanceAjaxForm::buildForm()

Form constructor.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

Return value

array The form structure.

Overrides EntityForm::buildForm

File

src/Form/FieldInheritanceAjaxForm.php, line 81

Class

FieldInheritanceAjaxForm
Provides an AJAX form for managing field inheritance entities.

Namespace

Drupal\field_inheritance\Form

Code

public function buildForm(array $form, FormStateInterface $form_state) {
  $form = parent::buildForm($form, $form_state);
  $form['actions']['submit']['#ajax'] = [
    'callback' => '::ajaxSubmit',
  ];
  return $form;
}