Remove menu

@param \Fulgurio\LightCMSBundle\Entity\PageMenu $menu
775863
public function removeMenu(\Fulgurio\LightCMSBundle\Entity\PageMenu $menu)
    {
        $this->menu->removeElement($menu);
    }
45059
public function setMenu(\Wucdbm\Bundle\MenuBuilderBundle\Entity\Menu $menu) {
        $this->menu = $menu;

        return $this;
    }
592261
public function removeMenuItem(MenuItemInterface $item): void
    {
        $key = array_search($item, $this->menuItems, true);
        if ($key !== false) {
            unset($this->menuItems[$key]);
        }
    }
901540
public function setMenu(\Core\Entity\Menu $menu = null) {
        $this->menu = $menu;

        return $this;
    }
1240246
public function removeMetum(\Fulgurio\LightCMSBundle\Entity\PageMeta $meta)
    {
        $this->meta->removeElement($meta);
    }
1203011
public function newMenuItemAction(Menu $menu)
    {
        $em = $this->getDoctrine()->getManager();

        $entity = new MenuItem();
        $entity->setMenu($menu);
        $form = $this->createMenuItemCreateForm($entity);

        return array(
            'entity' => $entity,
            'form' => $form->createView(),
        );
    }
1098347
public function delete(string $id = null): void
    {
        $this->request->allowMethod(['post', 'delete']);
        $menuItem = $this->MenuItems->get($id);
        if ($this->MenuItems->delete($menuItem)) {
            $this->Flash->success((string)__('The menu item has been deleted.'));
        } else {
            $this->Flash->error((string)__('The menu item could not be deleted. Please, try again.'));
        }

        $this->redirect($this->referer());
    }
382696
public function removeMenuItem($alias, $parent = null)
    {
        if ($parent !== null) {
            if (!isset($this->_menuItems[$parent]) ||
                !isset($this->_menuItems[$parent]['children']) ||
                !isset($this->_menuItems[$parent]['children'][$alias])
            ) {
                return;
            }
            unset($this->_menuItems[$parent]['children'][$alias]);
            return;
        }

        if (!isset($this->_menuItems[$alias])) {
            return;
        }
        unset($this->_menuItems[$alias]);
    }
1220306
public function removeItem(\Interne\SeanceBundle\Entity\Item $item)
    {
        $this->items->removeElement($item);
    }
934267
public void removeMenuPresenter(MenuPresenter presenter) {
        for (WeakReference<MenuPresenter> ref : mPresenters) {
            final MenuPresenter item = ref.get();
            if (item == null || item == presenter) {
                mPresenters.remove(ref);
            }
        }
    }
1011860
protected function reduceMenu (Menu $menu)
    {
        $reduced = ['button' => []];

        foreach ($menu->getItems() as $menuItem) {
            $reduced['button'][] = $this->reduceItem($menuItem);
        }

        return $reduced;
    }
55006
public function removePage(Page $page): Category
    {
        $this->children->removeElement($page);

        $page->setCategory(null);

        return $this;
    }
914740
public function setMenuPage(\Core\Entity\MenuPage $menuPage = null)
    {
        $this->menuPage = $menuPage;

        return $this;
    }
1091034
public function removeParameter(\Wucdbm\Bundle\MenuBuilderBundle\Entity\RouteParameter $parameter) {
        $this->parameters->removeElement($parameter);
    }
999361
public function delete($id)
    {
        $this->request->allowMethod('post');

        $menu = $this->Menus->get($id);
        if ($this->Menus->delete($menu)) {
            $this->Flash->success(__d('wasabi_core', 'The menu <strong>{0}</strong> has been deleted.', $menu->name));
        } else {
            $this->Flash->error($this->dbErrorMessage);
        }
        $this->redirect(['action' => 'index']);
        return;
    }
892127
public function removeLocation(\CampaignChain\CoreBundle\Entity\Location $location)
    {
        $this->locations->removeElement($location);
    }
787062
protected function clearSelectedMenuEntries(Menu $menu) {

		while(($e = $menu->getSelectedEntry())) {

			// dynamic menus come either with unselected entry or have a selected entry explicitly set

			if($menu->getType() == 'static') {
				$menu->clearSelectedEntry();
			}
			if(!($menu = $e->getSubMenu())) {
				break;
			}
		}
	}