public function actionRemoveItem() { if (!CSession::isAuth()) { $this->redirectNoAccess(); } $item = CMenuManager::getMenuItem(CRequest::getInt("id")); $id = $item->getMenu()->getId(); $item->remove(); $this->redirect("?action=view&id=" . $id); }
public function getParent() { if (is_null($this->_parent)) { if ($this->getParentId() != 0) { $parent = CMenuManager::getMenuItem($this->getParentId()); if (!is_null($parent)) { $this->_parent = $parent; } } } return $this->_parent; }