buildOverviewForm example



    // Add menu links administration form for existing menus.     if (!$menu->isNew() || $menu->isLocked()) {
      // Form API supports constructing and validating self-contained sections       // within forms, but does not allow handling the form section's submission       // equally separated yet. Therefore, we use a $form_state key to point to       // the parents of the form section.       // @see self::submitOverviewForm()       $form_state->set('menu_overview_form_parents', ['links']);
      $form['links'] = [];
      $form['links'] = $this->buildOverviewForm($form['links']$form_state);
    }

    return parent::form($form$form_state);
  }

  /** * Returns whether a menu name already exists. * * @param string $value * The name of the menu. * * @return bool * Returns TRUE if the menu already exists, FALSE otherwise. */
Home | Imprint | This part of the site doesn't use cookies.