You are here

public function AdminSettingsForm::tipsyAddOneOption in Tipsy 8

Function to add one option.

File

src/Form/AdminSettingsForm.php, line 54

Class

AdminSettingsForm
Class AdminSettingsForm.

Namespace

Drupal\tipsy\Form

Code

public function tipsyAddOneOption(array $form, FormStateInterface $form_state) {
  $options_count = $this->configFactory
    ->get("total_options");
  $options_count++;
  $this->configFactory
    ->set('total_options', $options_count);
  $form_state
    ->setRebuild();
}