You are here

public function LdapUserMappingBaseForm::mappingsAddAnother in Lightweight Directory Access Protocol (LDAP) 8.4

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 that we can modify.

File

ldap_user/src/Form/LdapUserMappingBaseForm.php, line 375

Class

LdapUserMappingBaseForm
Provides the form to configure user configuration and field mapping.

Namespace

Drupal\ldap_user\Form

Code

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