You are here

public function MegaMenuAdd::submitForm in The Better Mega Menu 2.x

Same name and namespace in other branches
  1. 8 src/Form/MegaMenuAdd.php \Drupal\tb_megamenu\Form\MegaMenuAdd::submitForm()

Overrides EntityForm::submitForm

See also

\Drupal\Core\Entity\EntityForm::submitForm()

File

src/Form/MegaMenuAdd.php, line 128

Class

MegaMenuAdd
Form handler for adding MegaMenuConfig entities.

Namespace

Drupal\tb_megamenu\Form

Code

public function submitForm(array &$form, FormStateInterface $form_state) {
  $id = $form_state
    ->getValue('menu') . '__' . $form_state
    ->getValue('theme');
  $form_state
    ->setValue('id', $id);
  parent::submitForm($form, $form_state);
}