/** * Show subhiearchy of pages and subchapters */ function showHierarchy() { global $lng, $ilCtrl; $this->setTabs(); $ilCtrl->setParameter($this, "backcmd", "showHierarchy"); include_once "./Modules/LearningModule/classes/class.ilChapterHierarchyFormGUI.php"; $form_gui = new ilChapterHierarchyFormGUI($this->content_object->getType(), $_GET["transl"]); $form_gui->setFormAction($ilCtrl->getFormAction($this)); $form_gui->setTitle($this->obj->getTitle()); $form_gui->setIcon(ilUtil::getImagePath("icon_st.png")); $form_gui->setTree($this->tree); $form_gui->setCurrentTopNodeId($this->obj->getId()); $form_gui->addMultiCommand($lng->txt("delete"), "delete"); $form_gui->addMultiCommand($lng->txt("cut"), "cutItems"); $form_gui->addMultiCommand($lng->txt("copy"), "copyItems"); $form_gui->addMultiCommand($lng->txt("cont_de_activate"), "activatePages"); if ($this->content_object->getLayoutPerPage()) { $form_gui->addMultiCommand($lng->txt("cont_set_layout"), "setPageLayout"); } $form_gui->setDragIcon(ilUtil::getImagePath("icon_pg_s.png")); $form_gui->addCommand($lng->txt("cont_save_all_titles"), "saveAllTitles"); $form_gui->addHelpItem($lng->txt("cont_chapters_after_pages")); $up_gui = $this->content_object->getType() == "dbk" ? "ilobjdlbookgui" : "ilobjlearningmodulegui"; $ilCtrl->setParameterByClass($up_gui, "active_node", $this->obj->getId()); $form_gui->setExplorerUpdater("tree", "tree_div", $ilCtrl->getLinkTargetByClass($up_gui, "explorer", "", true)); $ilCtrl->setParameterByClass($up_gui, "active_node", ""); $ctpl = new ilTemplate("tpl.chap_and_pages.html", true, true, "Modules/LearningModule"); $ctpl->setVariable("HIERARCHY_FORM", $form_gui->getHTML()); $ilCtrl->setParameter($this, "obj_id", $_GET["obj_id"]); include_once "./Modules/LearningModule/classes/class.ilObjContentObjectGUI.php"; $ml_head = ilObjContentObjectGUI::getMultiLangHeader($this->content_object->getId(), $this); $this->tpl->setContent($ml_head . $ctpl->get()); }