You are here

public function AuthorizationProfileForm::mappingsAddAnother in Authorization 8

Functionality for our ajax callback.

Parameters

array $form: The form being passed in.

\Drupal\Core\Form\FormStateInterface $form_state: The form state, passed by reference so we can modify.

File

src/Form/AuthorizationProfileForm.php, line 711

Class

AuthorizationProfileForm
Authorization profile form.

Namespace

Drupal\authorization\Form

Code

public function mappingsAddAnother(array &$form, FormStateInterface $form_state) : void {
  $form_state
    ->set('mappings_fields', $form_state
    ->get('mappings_fields') + 1);
  $form_state
    ->setRebuild();
}