ILIAS  trunk Revision v13.0_alpha-62-g3b72d83f2e5
ilObjContentObjectGUI Class Reference

Class ilObjContentObjectGUI. More...

+ Inheritance diagram for ilObjContentObjectGUI:
+ Collaboration diagram for ilObjContentObjectGUI:

Public Member Functions

 __construct ( $a_data, int $a_id=0, bool $a_call_by_reference=true, bool $a_prepare_output=false)
 
 properties ()
 edit properties form More...
 
 initPropertiesForm ()
 Init properties form. More...
 
 getPropertiesFormValues ()
 Get values for properties form. More...
 
 saveProperties ()
 save properties More...
 
 initMenuForm ()
 
 editMenuProperties ()
 
 saveMenuProperties ()
 
 proceedDragDrop ()
 
 delete (int $a_parent_subobj_id=0, ?int $page_id=null)
 confirm deletion screen for free pages (other usages do not apply anymore) More...
 
 deletePage (int $id)
 
 cancelDelete ()
 
 confirmedDelete (int $a_parent_subobj_id=0)
 delete page object or structure objects More...
 
 chapters ()
 show chapters More...
 
 pages ()
 
 listLinks ()
 List all broken links. More...
 
 showMaintenance ()
 Show maintenance. More...
 
 activatePages (int $id=0)
 activates or deactivates pages More...
 
 copyPage (int $id=0)
 
 getContextPath (int $a_endnode_id, int $a_startnode_id=1)
 
 showActions (array $a_actions)
 
 view ()
 
 moveChapter (int $a_parent_subobj_id=0)
 move a single chapter (selection) More...
 
 copyChapter ()
 
 pasteChapter ()
 
 movePage (int $id=0)
 
 cancel ()
 
 export ()
 
 fixTreeConfirm ()
 
 fixTree ()
 
 exportHTML ()
 
 addLocations (bool $a_omit_obj_id=false)
 display locator More...
 
 listQuestions ()
 
 listQuestionUsages ()
 
 listBlockedUsers ()
 
 resetNumberOfTries (string|array $user_q_ids=[])
 
 unlockQuestion (string|array $user_q_ids=[])
 
 sendMailToBlockedUsers (string|array $user_q_ids=[])
 
 setContentSubTabs (string $a_active)
 
 setMediaSubTabs (string $a_active)
 
 setQuestionsSubTabs (string $a_active)
 
 addTabs (string $a_act="")
 
 setSubTabs (string $a_active)
 
 __initLMMenuEditor ()
 
 addMenuEntry (?ilPropertyFormGUI $form=null)
 display add menu entry form More...
 
 initMenuEntryForm (string $a_mode="edit")
 
 saveMenuEntry ()
 
 confirmDeleteMenuEntry (int $id)
 
 confirmedDeleteMenuEntry ()
 
 activateMenuEntry (int $id)
 
 deactivateMenuEntry (int $id)
 
 editMenuEntryFromTable (int $id)
 
 editMenuEntry (?ilPropertyFormGUI $form=null)
 
 updateMenuEntry ()
 
 showEntrySelector ()
 
 selectHeader (int $id=0)
 select page as header More...
 
 selectFooter (int $id=0)
 select page as footer More...
 
 saveAllTitles ()
 Save all titles of chapters/pages. More...
 
 cutItems (array $ids)
 
 copyItems (array $ids)
 Copy items to clipboard. More...
 
 cutChapter ()
 Cut chapter(s) More...
 
 showExportIDsOverview (bool $a_validation=false)
 
 filterHelpChapters ()
 
 editExportId (int $id)
 
 saveExportId ()
 
 saveHelpMapping ()
 
 editHelpMapping (int $id)
 
 showTooltipList ()
 
 editTooltip (int $id)
 
 saveTooltip ()
 
 deleteTooltip (int $id)
 
 confirmedDeleteTooltip ()
 
 addTooltip ()
 
 filterTooltips ()
 
 setPageLayoutInHierarchy ()
 Set layout for multiple pages. More...
 
 setPageLayout (int|bool $a_in_hierarchy=false)
 Set layout for multiple pages. More...
 
 initSetPageLayoutForm (array $ids=[])
 
 savePageLayout ()
 
 editGlossaries ()
 Edit automatically linked glossaries. More...
 
 showLMGlossarySelector ()
 
 confirmGlossarySelection ()
 
 selectLMGlossaryLink ()
 
 selectLMGlossary ()
 
 confirmRemoveLMGlossary (int $glo_id)
 
 removeLMGlossary ()
 
 editMasterLanguage ()
 
 switchToLanguage ()
 
 redrawHeaderAction ()
 
- Public Member Functions inherited from ilObjectGUI
 getRefId ()
 
 setAdminMode (string $mode)
 
 getAdminMode ()
 
 getObject ()
 
 executeCommand ()
 
 withReferences ()
 determines whether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode (bool $mode=true)
 If true, a creation screen is displayed the current [ref_id] does belong to the parent class The mode is determined in ilRepositoryGUI. More...
 
 getCreationMode ()
 
 prepareOutput (bool $show_sub_objects=true)
 
 getAdminTabs ()
 administration tabs show only permissions and trash folder More...
 
 getHTML ()
 
 confirmedDeleteObject ()
 confirmed deletion of object -> objects are moved to trash or deleted immediately, if trash is disabled More...
 
 cancelObject ()
 cancel action and go back to previous page More...
 
 createObject ()
 create new object form More...
 
 editAvailabilityPeriodObject ()
 
 saveAvailabilityPeriodObject ()
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 
 getDidacticTemplateVar (string $type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $obj, ?int $parent_node_id=null)
 Add object to tree at given position. More...
 
 editObject ()
 
 addExternalEditFormCustom (ilPropertyFormGUI $form)
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction (string $cmd, string $default_form_action="")
 Get form action for command (command is method name without "Object", e.g. More...
 
 isVisible (int $ref_id, string $type)
 
 viewObject ()
 viewObject container presentation for "administration -> repository, trash, permissions" More...
 
 deleteObject (bool $error=false)
 Display deletion confirmation screen. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 
 addToDeskObject ()
 
 removeFromDeskObject ()
 
- Public Member Functions inherited from ILIAS\Object\ImplementsCreationCallback
 callCreationCallback (\ilObject $object, \ilObjectDefinition $obj_definition, int $requested_crtcb)
 

Static Public Member Functions

static getMultiLangHeader (int $a_lm_id, object $a_gui_class, string $a_mode="")
 
static _goto (string $a_target)
 
static getLayoutOption (string $a_txt, string $a_var, string $a_def_option="")
 
- Static Public Member Functions inherited from ilObjectGUI
static _gotoRepositoryRoot (bool $raise_error=false)
 Goto repository root. More...
 
static _gotoRepositoryNode (int $ref_id, string $cmd="")
 
static _gotoSharedWorkspaceNode (int $wsp_id)
 

Protected Member Functions

 checkCtrlPath ()
 
 buildExportOptionsFormHTML ()
 
 buildExportOptionsFormXML ()
 
 showExportOptionsXML ()
 
 showExportOptionsHTML ()
 
 doExportXML ()
 
 doExportHTML ()
 
 afterSave (ilObject $new_object)
 Post (successful) object creation hook. More...
 
 normalizeBlockedUserIds (string|array $user_q_ids)
 
 getBlockedUsersMailSignature ()
 
 setTabs (string $a_act="")
 
 getMenuItemsTable ()
 
 getMenuEntryData (int $id)
 
 getHelpMappingTable ()
 
 getExportIdForm (int $id)
 
 getHelpMappingForm (int $id)
 
 getTooltipTable ()
 
 getTooltip (int $id)
 
 getTooltipForm (int $id)
 
 getGlossariesTable ()
 
 learningProgress ()
 Learning progress. More...
 
- Protected Member Functions inherited from ilObjectGUI
 getObjectService ()
 
 assignObject ()
 
 setTitleAndDescription ()
 
 createActionDispatcherGUI ()
 
 initHeaderAction (?string $sub_type=null, ?int $sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction (?ilObjectListGUI $list_gui=null)
 Insert header action into main template. More...
 
 addHeaderAction ()
 Add header action menu. More...
 
 redrawHeaderActionObject ()
 Ajax call: redraw action header only. More...
 
 setTabs ()
 set admin tabs More...
 
 setAdminTabs ()
 set admin tabs More...
 
 setLocator ()
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator (bool $omit=true)
 
 addAdminLocatorItems (bool $do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 getCreationFormsHTML (StandardForm|ilPropertyFormGUI|array $form)
 
 getTitleForCreationFormPage ()
 
 getCreationFormTitle ()
 
 initCreateForm (string $new_type)
 
 didacticTemplatesToForm ()
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 
 retrieveAdditionalDidacticTemplateOptions ()
 
 addAdoptContentLinkToToolbar ()
 
 addImportButtonToToolbar ()
 
 addAvailabilityPeriodButtonToToolbar (ilToolbarGUI $toolbar)
 
 parseDidacticTemplateVar (string $var, string $type)
 
 afterSave (ilObject $new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 routeImportCmdObject ()
 
 importFile (string $file_to_import, string $path_to_uploaded_file_in_temp_dir)
 
 deleteUploadedImportFile (string $path_to_uploaded_file_in_temp_dir)
 
 afterImport (ilObject $new_object)
 Post (successful) object import hook. More...
 
 setFormAction (string $cmd, string $form_action)
 
 getReturnLocation (string $cmd, string $default_location="")
 Get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation (string $cmd, string $location)
 set specific return location for command More...
 
 getTargetFrame (string $cmd, string $default_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame (string $cmd, string $target_frame)
 Set specific target frame for command. More...
 
 showPossibleSubObjects ()
 show possible sub objects (pull down menu) More...
 
 getTabs ()
 @abstract overwrite in derived GUI class of your object type More...
 
 redirectToRefId (int $ref_id, string $cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current ["ref_id"] value of the request More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 checkPermission (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 checkPermissionBool (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 getCreatableObjectTypes ()
 
 buildAddNewItemElements (array $subtypes, string $create_target_class=ilRepositoryGUI::class, ?int $redirect_target_ref_id=null,)
 
 buildGroup (string $create_target_class, array $obj_types_in_group, string $title, array $subtypes)
 

Protected Attributes

ILIAS LearningModule InternalGUIService $gui
 
ILIAS LearningModule InternalDomainService $domain
 
ILIAS COPage Page PageManagerInterface $page_manager
 
ilRbacSystem $rbacsystem
 
ILIAS LearningModule ReadingTime SettingsGUI $reading_time_gui
 
ilLMMenuEditor $lmme_obj
 
ilObjLearningModule $lm_obj
 
string $lang_switch_mode
 
ilPropertyFormGUI $form
 
ilTabsGUI $tabs
 
ilHelpGUI $help
 
ilDBInterface $db
 
ilLogger $log
 
ILIAS DI UIServices $ui
 
ilComponentRepository $component_repository
 
bool $to_props = false
 
int $requested_obj_id = 0
 
string $requested_new_type = ""
 
string $requested_baseClass = ""
 
int $requested_ref_id = 0
 
string $requested_transl = ""
 
string $requested_backcmd = ""
 
int $requested_menu_entry = 0
 
int $requested_lm_menu_expand = 0
 
int $requested_search_root_expand = 0
 
bool $requested_hierarchy = false
 
int $requested_root_id = 0
 
int $requested_glo_id = 0
 
int $requested_glo_ref_id = 0
 
string $requested_lang_switch_mode = ""
 
int $requested_active_node = 0
 
int $requested_lmexpand = 0
 
int $requested_link_ref_id = 0
 
string $requested_totransl = ""
 
bool $requested_lmmovecopy = false
 
ilObjLearningModule $lm
 
EditingGUIRequest $edit_request
 
ILIAS Style Content Service $content_style_service
 
ilLMTree $lm_tree
 
- Protected Attributes inherited from ilObjectGUI
ILIAS Notes Service $notes_service
 
GlobalHttpState $http
 
ServerRequestInterface $request
 
ilLocatorGUI $locator
 
ilObjUser $user
 
ilAccessHandler $access
 
ilSetting $settings
 
ilToolbarGUI $toolbar
 
ilRbacAdmin $rbac_admin
 
ilRbacSystem $rbac_system
 
ilRbacReview $rbac_review
 
ilObjectService $object_service
 
ilObjectDefinition $obj_definition
 
ilGlobalTemplateInterface $tpl
 
ilTree $tree
 
ilCtrl $ctrl
 
ilErrorHandling $error
 
ilLanguage $lng
 
ilTabsGUI $tabs_gui
 
ILIAS $ilias
 
ArrayBasedRequestWrapper $post_wrapper
 
RequestWrapper $request_wrapper
 
Refinery $refinery
 
ilFavouritesManager $favourites
 
CustomIconFactory $custom_icon_factory
 
UIFactory $ui_factory
 
UIRenderer $ui_renderer
 
Filesystem $temp_file_system
 
ilObject $object = null
 
bool $creation_mode = false
 
 $data
 
int $id
 
bool $call_by_reference = false
 
bool $prepare_output
 
int $ref_id
 
int $obj_id
 
int $maxcount
 
array $form_action = []
 
array $return_location = []
 
array $target_frame = []
 
string $tmp_import_dir
 
string $sub_objects = ""
 
bool $omit_locator = false
 
string $type = ""
 
string $admin_mode = self::ADMIN_MODE_NONE
 
int $requested_ref_id = 0
 
int $requested_crtptrefid = 0
 
int $requested_crtcb = 0
 
string $requested_new_type = ""
 
string $link_params
 
string $html = ""
 

Additional Inherited Members

- Data Fields inherited from ilObjectGUI
const ADMIN_MODE_NONE = ""
 
const ADMIN_MODE_SETTINGS = "settings"
 
const ADMIN_MODE_REPOSITORY = "repository"
 
const UPLOAD_TYPE_LOCAL = 1
 
const UPLOAD_TYPE_UPLOAD_DIRECTORY = 2
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 
const SUPPORTED_IMPORT_MIME_TYPES = [MimeType::APPLICATION__ZIP, MimeType::APPLICATION__X_ZIP_COMPRESSED]
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilObjContentObjectGUI::__construct (   $a_data,
int  $a_id = 0,
bool  $a_call_by_reference = true,
bool  $a_prepare_output = false 
)
Parameters
mixed$a_data
int$a_id
bool$a_call_by_reference
bool$a_prepare_output
Exceptions
ilCtrlException

Reimplemented in ilObjLearningModuleGUI.

Definition at line 92 of file class.ilObjContentObjectGUI.php.

97 {
98 global $DIC;
99
100 $this->lng = $DIC->language();
101 $this->access = $DIC->access();
102 $this->tabs = $DIC->tabs();
103 $this->settings = $DIC->settings();
104 $this->user = $DIC->user();
105 $this->tpl = $DIC["tpl"];
106 $this->toolbar = $DIC->toolbar();
107 $this->rbacsystem = $DIC->rbac()->system();
108 $this->tree = $DIC->repositoryTree();
109 $this->help = $DIC["ilHelp"];
110 $this->locator = $DIC["ilLocator"];
111 $this->db = $DIC->database();
112 $this->log = $DIC["ilLog"];
113 $this->ui = $DIC->ui();
114 $lng = $DIC->language();
115 $ilCtrl = $DIC->ctrl();
116 $this->ctrl = $ilCtrl;
117 $this->component_repository = $DIC["component.repository"];
118 $lng->loadLanguageModule("content");
119 $lng->loadLanguageModule("obj");
120 parent::__construct($a_data, $a_id, $a_call_by_reference, false);
121
122 $this->edit_request = $DIC
123 ->learningModule()
124 ->internal()
125 ->gui()
126 ->editing()
127 ->request();
128
130 $this->to_props = $req->getToProps();
131 $this->requested_obj_id = $req->getObjId();
132 $this->requested_ref_id = $req->getRefId();
133 $this->requested_root_id = $req->getRootId();
134 $this->requested_glo_id = $req->getGlossaryId();
135 $this->requested_glo_ref_id = $req->getGlossaryRefId();
136 $this->requested_menu_entry = $req->getMenuEntry();
137 $this->requested_lm_menu_expand = $req->getLMMenuExpand();
138 $this->requested_search_root_expand = $req->getSearchRootExpand();
139 $this->requested_new_type = $req->getNewType();
140 $this->requested_baseClass = $req->getBaseClass();
141 $this->requested_transl = $req->getTranslation();
142 $this->requested_backcmd = $req->getBackCmd();
143 $this->requested_hierarchy = $req->getHierarchy();
144 $this->lang_switch_mode = $req->getLangSwitchMode();
145 $this->requested_active_node = $req->getActiveNode();
146 $this->requested_lmexpand = $req->getLMExpand();
147 $this->requested_link_ref_id = $req->getLinkRefId();
148 $this->requested_totransl = $req->getToTranslation();
149 $this->requested_lmmovecopy = $req->getLMMoveCopy();
150 $this->content_style_service = $DIC
151 ->contentStyle();
152
153 $id = (isset($this->object))
154 ? $this->object->getId()
155 : 0;
156 $this->reading_time_gui = new \ILIAS\LearningModule\ReadingTime\SettingsGUI($id);
157 $this->domain = $DIC->learningModule()->internal()->domain();
158 $this->gui = $DIC->learningModule()->internal()->gui();
159 $this->page_manager = $this->domain->pageManager();
160 }
loadLanguageModule(string $a_module)
Load language module.
ilLanguage $lng
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
catch(\Exception $e) $req
Definition: xapiproxy.php:81
global $DIC
Definition: shib_login.php:26

References $DIC, $edit_request, ilObjectGUI\$id, ilObjectGUI\$lng, XapiProxy\$req, ILIAS\GlobalScreen\Provider\__construct(), ILIAS\Repository\access(), ILIAS\Repository\ctrl(), ILIAS\Repository\help(), ILIAS\Repository\lng(), ilLanguage\loadLanguageModule(), ILIAS\Repository\locator(), ILIAS\Repository\object(), ILIAS\Repository\settings(), ILIAS\Repository\tabs(), ILIAS\Repository\toolbar(), ILIAS\Repository\ui(), and ILIAS\Repository\user().

+ Here is the call graph for this function:

Member Function Documentation

◆ __initLMMenuEditor()

ilObjContentObjectGUI::__initLMMenuEditor ( )

Definition at line 2065 of file class.ilObjContentObjectGUI.php.

2065 : void
2066 {
2067 $this->lmme_obj = new ilLMMenuEditor();
2068 $this->lmme_obj->setObjId($this->lm->getId());
2069 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

◆ _goto()

static ilObjContentObjectGUI::_goto ( string  $a_target)
static

Definition at line 2417 of file class.ilObjContentObjectGUI.php.

2417 : void
2418 {
2419 global $DIC;
2420 $main_tpl = $DIC->ui()->mainTemplate();
2421
2422 $ilAccess = $DIC->access();
2423 $ilErr = $DIC["ilErr"];
2424 $lng = $DIC->language();
2425 $ctrl = $DIC->ctrl();
2426
2427 if ($ilAccess->checkAccess("read", "", $a_target)) {
2428 $ctrl->setParameterByClass("ilLMPresentationGUI", "ref_id", $a_target);
2429 if (ilObjLearningModuleAccess::_lookupSetting("lm_starting_point") == "first") {
2430 $ctrl->redirectByClass("ilLMPresentationGUI", "");
2431 } else {
2432 $ctrl->redirectByClass("ilLMPresentationGUI", "resume");
2433 }
2434 } elseif ($ilAccess->checkAccess("visible", "", $a_target)) {
2435 $ctrl->setParameterByClass("ilLMPresentationGUI", "ref_id", $a_target);
2436 $ctrl->redirectByClass("ilLMPresentationGUI", "infoScreen");
2437 } elseif ($ilAccess->checkAccess("read", "", ROOT_FOLDER_ID)) {
2438 $main_tpl->setOnScreenMessage('failure', sprintf(
2439 $lng->txt("msg_no_perm_read_item"),
2441 ), true);
2443 }
2444
2445
2446 $ilErr->raiseError($lng->txt("msg_no_perm_read_lm"), $ilErr->FATAL);
2447 }
redirectByClass( $a_class, ?string $a_cmd=null, ?string $a_anchor=null, bool $is_async=false)
@inheritDoc
setParameterByClass(string $a_class, string $a_parameter, $a_value)
@inheritDoc
txt(string|LanguageIdentifier $a_topic, ?int $n=null)
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
static _gotoRepositoryRoot(bool $raise_error=false)
Goto repository root.
static _lookupObjId(int $ref_id)
static _lookupTitle(int $obj_id)
const ROOT_FOLDER_ID
Definition: constants.php:32

References $DIC, $lng, ilObjectGUI\_gotoRepositoryRoot(), ilObject\_lookupObjId(), ilObjLearningModuleAccess\_lookupSetting(), ilObject\_lookupTitle(), and ROOT_FOLDER_ID.

Referenced by ILIAS\StaticURL\Handler\LegacyGotoHandler\handle().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ activateMenuEntry()

ilObjContentObjectGUI::activateMenuEntry ( int  $id)

Definition at line 2248 of file class.ilObjContentObjectGUI.php.

2248 : void
2249 {
2251 $this->ctrl->redirect($this, "editMenuProperties");
2252 }
static writeActive(int $entry_id, bool $active)

References $id, ILIAS\Repository\ctrl(), and ilLMMenuEditor\writeActive().

+ Here is the call graph for this function:

◆ activatePages()

ilObjContentObjectGUI::activatePages ( int  $id = 0)

activates or deactivates pages

Definition at line 1302 of file class.ilObjContentObjectGUI.php.

1302 : void
1303 {
1304 $ids = $id > 0 ? [$id] : $this->edit_request->getIds();
1305 foreach ($ids as $id) {
1306 $act = $this->page_manager->lookupActive($id, $this->lm->getType());
1307 $this->page_manager->writeActive($id, $this->lm->getType(), !$act);
1308 }
1309
1310 $this->ctrl->redirect($this, "pages");
1311 }

References $id, and ILIAS\Repository\ctrl().

+ Here is the call graph for this function:

◆ addLocations()

ilObjContentObjectGUI::addLocations ( bool  $a_omit_obj_id = false)

display locator

Parameters
bool$a_omit_obj_idset to true, if obj id is not page id (e.g. permission gui)

Definition at line 1579 of file class.ilObjContentObjectGUI.php.

1581 : void {
1583
1584 $obj_id = 0;
1585 if (!$a_omit_obj_id) {
1587 }
1588 $lmtree = $this->lm->getTree();
1589 if (($obj_id != 0) && $lmtree->isInTree($obj_id)) {
1590 $path = $lmtree->getPathFull($obj_id);
1591 } else {
1592 $path = $lmtree->getPathFull($lmtree->getRootId());
1593 if ($obj_id != 0) {
1594 $path[] = array("type" => "pg", "child" => $this->obj_id,
1595 "title" => ilLMPageObject::_getPresentationTitle($this->obj_id));
1596 }
1597 }
1598
1599 foreach ($path as $key => $row) {
1600 if ($row["child"] == 1) {
1601 $this->ctrl->setParameter($this, "obj_id", null);
1602 $locator->addItem($this->lm->getTitle(), $this->ctrl->getLinkTarget($this, "chapters"));
1603 } else {
1604 $title = $row["title"];
1605 switch ($row["type"]) {
1606 case "st":
1607 $this->ctrl->setParameterByClass("ilstructureobjectgui", "obj_id", $row["child"]);
1608 $locator->addItem($title, $this->ctrl->getLinkTargetByClass("ilstructureobjectgui", "view"));
1609 break;
1610
1611 case "pg":
1612 $this->ctrl->setParameterByClass("illmpageobjectgui", "obj_id", $row["child"]);
1613 $locator->addItem($title, $this->ctrl->getLinkTargetByClass("illmpageobjectgui", "edit"));
1614 break;
1615 }
1616 }
1617 }
1618 if (!$a_omit_obj_id) {
1619 $this->ctrl->setParameter($this, "obj_id", $this->requested_obj_id);
1620 }
1621 }
static _getPresentationTitle(int $a_pg_id, string $a_mode=self::CHAPTER_TITLE, bool $a_include_numbers=false, bool $a_time_scheduled_activation=false, bool $a_force_content=false, int $a_lm_id=0, string $a_lang="-", bool $a_include_short=false)
presentation title doesn't have to be page title, it may be chapter title + page title or chapter tit...
ilLocatorGUI $locator

Referenced by doExportHTML(), doExportXML(), showExportOptionsHTML(), and showExportOptionsXML().

+ Here is the caller graph for this function:

◆ addMenuEntry()

ilObjContentObjectGUI::addMenuEntry ( ?ilPropertyFormGUI  $form = null)

display add menu entry form

Definition at line 2074 of file class.ilObjContentObjectGUI.php.

2074 : void
2075 {
2076 $ilTabs = $this->tabs;
2077 $ilToolbar = $this->toolbar;
2078 $ilCtrl = $this->ctrl;
2079
2080 $this->setTabs();
2081
2082 $ilTabs->setTabActive("settings");
2083 $this->setSubTabs("cont_lm_menu");
2084
2085 $ilToolbar->addButton(
2086 $this->lng->txt("lm_menu_select_internal_object"),
2087 $ilCtrl->getLinkTarget($this, "showEntrySelector")
2088 );
2089
2090 if (is_null($form)) {
2091 $form = $this->initMenuEntryForm("create");
2092 }
2093 $this->tpl->setContent($form->getHTML());
2094 }
initMenuEntryForm(string $a_mode="edit")
setTabs()
set admin tabs
ilToolbarGUI $toolbar

References ilPropertyFormGUI\getHTML(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ addTabs()

ilObjContentObjectGUI::addTabs ( string  $a_act = "")

Definition at line 1907 of file class.ilObjContentObjectGUI.php.

1907 : void
1908 {
1910 $ilTabs = $this->tabs;
1911 $lng = $this->lng;
1912
1913 // content -> pages
1914 $this->ctrl->setParameterByClass(static::class, "sub_type", "st");
1915 if ($this->access->checkAccess("write", "", $this->ref_id)) {
1916 $ilTabs->addTab(
1917 "content",
1918 $lng->txt("content"),
1919 $this->ctrl->getLinkTargetByClass(EditSubObjectsGUI::class)
1920 );
1921
1922 // media
1923 $this->lng->loadLanguageModule('mob');
1924 $ilTabs->addTab(
1925 "media",
1926 $lng->txt("mob_media"),
1927 $this->ctrl->getLinkTargetByClass(ilMediaObjectOverviewGUI::class, "show")
1928 );
1929
1930 // questions
1931 $ilTabs->addTab(
1932 "questions",
1933 $lng->txt("objs_qst"),
1934 $this->ctrl->getLinkTarget($this, "listQuestionUsages")
1935 );
1936
1937 // info
1938 if ($this->object->isInfoEnabled()) {
1939 $ilTabs->addTab(
1940 "info",
1941 $lng->txt("info_short"),
1942 $this->ctrl->getLinkTargetByClass("ilinfoscreengui", 'showSummary')
1943 );
1944 }
1945
1946 $ilTabs->addTab(
1947 "settings",
1948 $lng->txt("settings"),
1949 $this->ctrl->getLinkTarget($this, 'properties')
1950 );
1951 }
1952
1953 // learning progress
1954 if (ilLearningProgressAccess::checkAccess($this->lm->getRefId()) and ($this->lm->getType() == 'lm')) {
1955 $ilTabs->addTab(
1956 'learning_progress',
1957 $lng->txt("learning_progress"),
1958 $this->ctrl->getLinkTargetByClass(array('illearningprogressgui'), '')
1959 );
1960 }
1961
1962 // meta data
1963 if ($this->access->checkAccess("write", "", $this->ref_id)) {
1964 $mdgui = new ilObjectMetaDataGUI($this->lm);
1965 $mdtab = $mdgui->getTab();
1966 if ($mdtab) {
1967 $ilTabs->addTab(
1968 "meta",
1969 $lng->txt("meta_data"),
1970 $mdtab
1971 );
1972 }
1973
1974 // export
1975 $ilTabs->addTab(
1976 "export",
1977 $lng->txt("export"),
1978 $this->ctrl->getLinkTargetByClass("ilexportgui", "")
1979 );
1980 }
1981
1982 // permissions
1983 if ($rbacsystem->checkAccess('edit_permission', $this->lm->getRefId())) {
1984 $ilTabs->addTab(
1985 "perm",
1986 $lng->txt("perm_settings"),
1987 $this->ctrl->getLinkTargetByClass(array(get_class($this),'ilpermissiongui'), "perm")
1988 );
1989 }
1990
1991 if ($a_act != "") {
1992 $ilTabs->activateTab($a_act);
1993 }
1994
1995 if ($this->access->checkAccess("write", "", $this->ref_id)) {
1996 // presentation view
1997 $ilTabs->addNonTabbedLink(
1998 "pres_mode",
1999 $lng->txt("cont_presentation_view"),
2000 "ilias.php?baseClass=ilLMPresentationGUI&ref_id=" . $this->lm->getRefId()
2001 );
2002 }
2003 }
static checkAccess(int $a_ref_id, bool $a_allow_only_read=true)
check access to learning progress
Class ilObjectMetaDataGUI.
checkAccess(string $a_operations, int $a_ref_id, string $a_type="")
checkAccess represents the main method of the RBAC-system in ILIAS3 developers want to use With this ...

References $lng, ILIAS\Repository\access(), ilLearningProgressAccess\checkAccess(), ilRbacSystem\checkAccess(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ILIAS\Repository\object().

+ Here is the call graph for this function:

◆ addTooltip()

ilObjContentObjectGUI::addTooltip ( )

Definition at line 2856 of file class.ilObjContentObjectGUI.php.

2856 : void
2857 {
2858 $lng = $this->lng;
2859 $ilCtrl = $this->ctrl;
2860
2861 $tt_id = $this->edit_request->getTooltipId();
2862 if (trim($tt_id) != "") {
2863 if (is_int(strpos($tt_id, "_"))) {
2864 $this->help->internal()->domain()->tooltips()->addTooltip(trim($tt_id), "");
2865 $this->tpl->setOnScreenMessage('success', $lng->txt("msg_obj_modified"), true);
2866
2867 $fu = strpos($tt_id, "_");
2868 $comp = substr($tt_id, 0, $fu);
2869 ilSession::set("help_tt_comp", ilUtil::stripSlashes($comp));
2870 } else {
2871 $this->tpl->setOnScreenMessage('failure', $lng->txt("cont_help_no_valid_tooltip_id"), true);
2872 }
2873 }
2874 $ilCtrl->redirect($this, "showTooltipList");
2875 }
static set(string $a_var, $a_val)
Set a value.
static stripSlashes(string $a_str, bool $a_strip_html=true, string $a_allow="")

References $lng, ILIAS\Repository\help(), ilSession\set(), and ilUtil\stripSlashes().

+ Here is the call graph for this function:

◆ afterSave()

ilObjContentObjectGUI::afterSave ( ilObject  $new_object)
protected

Post (successful) object creation hook.

Reimplemented from ilObjectGUI.

Definition at line 1018 of file class.ilObjContentObjectGUI.php.

1018 : void
1019 {
1020 $new_object->setCleanFrames(true);
1021 $new_object->update();
1022
1023 // create content object tree
1024 $new_object->createLMTree();
1025
1026 // create a first chapter
1027 $new_object->addFirstChapterAndPage();
1028
1029 // always send a message
1030 $this->tpl->setOnScreenMessage('success', $this->lng->txt($this->type . "_added"), true);
1031 $this->ctrl->setParameterByClass(ilObjLearningModuleGUI::class, "ref_id", $new_object->getRefId());
1032 $this->ctrl->redirectByClass([ilLMEditorGUI::class, ilObjLearningModuleGUI::class], "");
1033 }

References ILIAS\Repository\ctrl(), ilObject\getRefId(), ILIAS\Repository\lng(), and ilObject\update().

+ Here is the call graph for this function:

◆ buildExportOptionsFormHTML()

ilObjContentObjectGUI::buildExportOptionsFormHTML ( )
protected

Definition at line 509 of file class.ilObjContentObjectGUI.php.

510 {
511 $this->lng->loadLanguageModule('exp');
512 $ot = $this->lm->getObjectProperties()->getPropertyTranslations();
513 $items = [];
514 if ($ot->getContentTranslationActivated()) {
515 $this->lng->loadLanguageModule("meta");
516 $langs = $ot->getLanguages();
517 foreach ($langs as $l => $ldata) {
518 $items["html_" . $l] = $this->lng->txt("meta_l_" . $l);
519 }
520 $items["html_all"] = $this->lng->txt("cont_all_languages");
521 }
522 if (!$ot->getContentTranslationActivated()) {
523 $items["exportHTML"] = "HTML";
524 }
525 $select = $this->ui->factory()->input()->field()->select($this->lng->txt("language"), $items)
526 ->withRequired(true);
527 $section = $this->ui->factory()->input()->field()->section(
528 [$select],
529 $this->lng->txt("export_options")
530 );
531 return $this->ui->factory()->input()->container()->form()->standard(
532 $this->ctrl->getLinkTargetByClass(ilObjContentObjectGUI::class, "doExportHTML"),
533 [$section]
534 )->withSubmitLabel($this->lng->txt("export"));
535 }
This describes a standard form.
Definition: Standard.php:30

References ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ILIAS\Repository\ui().

Referenced by doExportHTML().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ buildExportOptionsFormXML()

ilObjContentObjectGUI::buildExportOptionsFormXML ( )
protected

Definition at line 537 of file class.ilObjContentObjectGUI.php.

538 {
539 $this->lng->loadLanguageModule('exp');
540 $ot = $this->lm->getObjectProperties()->getPropertyTranslations();
541 $items = [];
542 if ($ot->getContentTranslationActivated()) {
543 $items["xml_master"] = $this->lng->txt("cont_master_language_only");
544 $items["xml_masternomedia"] = $this->lng->txt("cont_master_language_only_no_media");
545 $this->lng->loadLanguageModule("meta");
546 $langs = $ot->getLanguages();
547 }
548 $select = $this->ui->factory()->input()->field()->select($this->lng->txt("export_type"), $items)
549 ->withRequired(true);
550 $section = $this->ui->factory()->input()->field()->section(
551 [$select],
552 $this->lng->txt("export_options")
553 );
554 return $this->ui->factory()->input()->container()->form()->standard(
555 $this->ctrl->getLinkTargetByClass(ilObjContentObjectGUI::class, "doExportXML"),
556 [$section]
557 )->withSubmitLabel($this->lng->txt("export"));
558 }

References ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ILIAS\Repository\ui().

Referenced by doExportXML().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ cancel()

ilObjContentObjectGUI::cancel ( )

Definition at line 1514 of file class.ilObjContentObjectGUI.php.

1514 : void
1515 {
1516 if ($this->requested_new_type == "pg") {
1517 $this->ctrl->redirect($this, "pages");
1518 } else {
1519 $this->ctrl->redirect($this, "chapters");
1520 }
1521 }

References ILIAS\Repository\ctrl().

+ Here is the call graph for this function:

◆ cancelDelete()

ilObjContentObjectGUI::cancelDelete ( )

Definition at line 1093 of file class.ilObjContentObjectGUI.php.

1093 : void
1094 {
1095 $this->ctrl->redirect($this, $this->requested_backcmd);
1096 }

References ILIAS\Repository\ctrl().

Referenced by delete().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ chapters()

ilObjContentObjectGUI::chapters ( )

show chapters

Definition at line 1147 of file class.ilObjContentObjectGUI.php.

1147 : void
1148 {
1149 $this->gui->ctrl()->setParameterByClass(EditSubObjectsGUI::class, "sub_type", "st");
1150 $this->gui->ctrl()->redirectByClass(EditSubObjectsGUI::class);
1151 }

◆ checkCtrlPath()

ilObjContentObjectGUI::checkCtrlPath ( )
protected

Definition at line 162 of file class.ilObjContentObjectGUI.php.

162 : void
163 {
164 if (!$this->getCreationMode()) {
165 $baseclass = strtolower($this->requested_baseClass);
166 $next_class = strtolower($this->ctrl->getNextClass());
167 // all calls must be routed through illmpresentationgui or
168 // illmeditorgui...
169 if (!in_array($baseclass, ["illmpresentationgui", "illmeditorgui"])) {
170 // ...except the comman action handler routes to
171 // activation/condition GUI, see https://mantis.ilias.de/view.php?id=32858
172 if (in_array($next_class, ["ilcommonactiondispatchergui"])) {
173 return;
174 }
175 throw new ilLMException("Wrong ctrl path");
176 }
177 }
178 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References ILIAS\Repository\ctrl(), and ilObjectGUI\getCreationMode().

+ Here is the call graph for this function:

◆ confirmDeleteMenuEntry()

ilObjContentObjectGUI::confirmDeleteMenuEntry ( int  $id)

Definition at line 2201 of file class.ilObjContentObjectGUI.php.

2201 : void
2202 {
2203 $entry = $this->getMenuEntryData($id);
2204 if ($entry === null) {
2205 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_menu_entry_id"), true);
2206 $this->ctrl->redirect($this, "editMenuProperties");
2207 return;
2208 }
2209
2210 $this->getMenuItemsTable()->renderDeletionConfirmation(
2211 $this->lng->txt("delete"),
2212 $this->lng->txt("info_delete_sure"),
2213 "confirmedDeleteMenuEntry",
2214 [$id => (string) $entry["title"]]
2215 );
2216 }

References $id, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ confirmedDelete()

ilObjContentObjectGUI::confirmedDelete ( int  $a_parent_subobj_id = 0)

delete page object or structure objects

Parameters
int$a_parent_subobj_idid of parent object (structure object) of the objects, that should be deleted (or no parent object id for top level)

Definition at line 1105 of file class.ilObjContentObjectGUI.php.

1105 : void
1106 {
1107 $tree = new ilLMTree($this->lm->getId());
1108
1109 $ids = $this->edit_request->getIds();
1110
1111 // check number of objects
1112 if (count($ids) == 0) {
1113 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_checkbox"));
1114 $this->ctrl->redirect($this, "cancelDelete");
1115 }
1116
1117 // delete all selected objects
1118 foreach ($ids as $id) {
1119 if ($id != ilTree::POS_FIRST_NODE) {
1120 $obj = ilLMObjectFactory::getInstance($this->lm, $id, false);
1121 $node_data = $tree->getNodeData($id);
1122 if (is_object($obj)) {
1123 $obj->setLMId($this->lm->getId());
1124 $obj->delete();
1125 }
1126 if ($tree->isInTree($id)) {
1127 $tree->deleteTree($node_data);
1128 }
1129 }
1130 }
1131
1132 // check the tree
1133 $this->lm->checkTree();
1134
1135 // feedback
1136 $this->tpl->setOnScreenMessage('success', $this->lng->txt("info_deleted"), true);
1137
1138 if ($a_parent_subobj_id == 0) {
1139 $this->ctrl->redirect($this, $this->requested_backcmd);
1140 }
1141 }
static getInstance(ilObjLearningModule $a_content_obj, int $a_id=0, bool $a_halt=true)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
isInTree(?int $a_node_id)
get all information of a node.
getNodeData(int $a_node_id, ?int $a_tree_pk=null)
get all information of a node.
deleteTree(array $a_node)
delete node and the whole subtree under this node
const POS_FIRST_NODE

References ilObjectGUI\$id, ilObjectGUI\$tree, ILIAS\Repository\ctrl(), ilTree\deleteTree(), ilLMObjectFactory\getInstance(), ilTree\getNodeData(), ilTree\isInTree(), ILIAS\Repository\lng(), and ilTree\POS_FIRST_NODE.

+ Here is the call graph for this function:

◆ confirmedDeleteMenuEntry()

ilObjContentObjectGUI::confirmedDeleteMenuEntry ( )

Definition at line 2218 of file class.ilObjContentObjectGUI.php.

2218 : void
2219 {
2220 $table = $this->getMenuItemsTable();
2221 $ids = $table->getItemIds();
2222 if ($ids === []) {
2223 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_menu_entry_id"), true);
2224 $this->ctrl->redirect($this, "editMenuProperties");
2225 return;
2226 }
2227
2228 $valid_ids = [];
2229 foreach ($ids as $id) {
2230 if ($this->getMenuEntryData((int) $id) !== null) {
2231 $valid_ids[] = (int) $id;
2232 }
2233 }
2234 if ($valid_ids === []) {
2235 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_menu_entry_id"), true);
2236 $this->ctrl->redirect($this, "editMenuProperties");
2237 return;
2238 }
2239
2240 foreach ($valid_ids as $id) {
2241 $this->lmme_obj->delete($id);
2242 }
2243
2244 $this->tpl->setOnScreenMessage('success', $this->lng->txt("msg_entry_removed"), true);
2245 $this->ctrl->redirect($this, "editMenuProperties");
2246 }

References $id, ILIAS\Repository\ctrl(), ILIAS\Repository\int(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ confirmedDeleteTooltip()

ilObjContentObjectGUI::confirmedDeleteTooltip ( )

Definition at line 2843 of file class.ilObjContentObjectGUI.php.

2843 : void
2844 {
2845 $ids = $this->getTooltipTable()->getItemIds();
2846 foreach ($ids as $id) {
2847 if ($this->getTooltip((int) $id) !== null) {
2848 $this->help->internal()->domain()->tooltips()->deleteTooltip((int) $id);
2849 }
2850 }
2851
2852 $this->tpl->setOnScreenMessage("success", $this->lng->txt("msg_obj_modified"), true);
2853 $this->ctrl->redirect($this, "showTooltipList");
2854 }

References $id, ILIAS\Repository\ctrl(), ILIAS\Repository\help(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ confirmGlossarySelection()

ilObjContentObjectGUI::confirmGlossarySelection ( )

Definition at line 3090 of file class.ilObjContentObjectGUI.php.

3090 : void
3091 {
3092 $ilCtrl = $this->ctrl;
3093 $tpl = $this->tpl;
3094 $lng = $this->lng;
3095
3096 $cgui = new ilConfirmationGUI();
3097 $ilCtrl->setParameter($this, "glo_ref_id", $this->requested_root_id);
3098 $cgui->setFormAction($ilCtrl->getFormAction($this));
3099 $cgui->setHeaderText($lng->txt("cont_link_glo_in_lm"));
3100 $cgui->setCancel($lng->txt("no"), "selectLMGlossary");
3101 $cgui->setConfirm($lng->txt("yes"), "selectLMGlossaryLink");
3102 $tpl->setContent($cgui->getHTML());
3103 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
ilGlobalTemplateInterface $tpl
setContent(string $a_html)
Sets content for standard template.

References $lng, ILIAS\News\Common\Table\$tpl, and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ confirmRemoveLMGlossary()

ilObjContentObjectGUI::confirmRemoveLMGlossary ( int  $glo_id)

Definition at line 3130 of file class.ilObjContentObjectGUI.php.

3130 : void
3131 {
3132 $this->getGlossariesTable()->renderDeletionConfirmation(
3133 $this->lng->txt("remove"),
3134 $this->lng->txt("info_delete_sure"),
3135 "removeLMGlossary",
3136 [$glo_id => ilObject::_lookupTitle($glo_id)]
3137 );
3138 }

References ilObject\_lookupTitle(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ copyChapter()

ilObjContentObjectGUI::copyChapter ( )

Definition at line 1488 of file class.ilObjContentObjectGUI.php.

1488 : void
1489 {
1490 $this->copyItems();
1491 }
copyItems(array $ids)
Copy items to clipboard.

◆ copyItems()

ilObjContentObjectGUI::copyItems ( array  $ids)

Copy items to clipboard.

Definition at line 2478 of file class.ilObjContentObjectGUI.php.

2478 : void
2479 {
2480 $ilCtrl = $this->ctrl;
2481 $lng = $this->lng;
2482
2483 if (count($ids) == 0) {
2484 $this->tpl->setOnScreenMessage('failure', $lng->txt("no_checkbox"), true);
2485 $ilCtrl->redirect($this, "chapters");
2486 }
2487
2488 $todel = array(); // delete IDs < 0 (needed for non-js editing)
2489 foreach ($ids as $k => $item) {
2490 if ($item < 0) {
2491 $todel[] = $k;
2492 }
2493 }
2494 foreach ($todel as $k) {
2495 unset($ids[$k]);
2496 }
2497 ilLMObject::clipboardCopy($this->lm->getId(), $ids);
2499 $this->tpl->setOnScreenMessage('info', $lng->txt("cont_selected_items_have_been_copied"), true);
2500 $ilCtrl->redirect($this, "chapters");
2501 }
static setAction(string $a_action)
static clipboardCopy(int $a_cont_obj_id, array $a_ids)
Copy a set of chapters/pages into the clipboard.

References $lng, ilLMObject\clipboardCopy(), and ilEditClipboard\setAction().

+ Here is the call graph for this function:

◆ copyPage()

ilObjContentObjectGUI::copyPage ( int  $id = 0)

Definition at line 1370 of file class.ilObjContentObjectGUI.php.

1370 : void
1371 {
1372 $ids = $id > 0 ? [$id] : $this->edit_request->getIds();
1373 if (count($ids) == 0) {
1374 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_checkbox"));
1375 $this->ctrl->redirect($this, "pages");
1376 }
1377
1378 ilLMObject::clipboardCopy($this->lm->getId(), $ids);
1380
1381 $this->tpl->setOnScreenMessage('info', $this->lng->txt("cont_selected_items_have_been_copied"), true);
1382
1383 $this->ctrl->redirect($this, "pages");
1384 }

References $id, ilLMObject\clipboardCopy(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ilEditClipboard\setAction().

+ Here is the call graph for this function:

◆ cutChapter()

ilObjContentObjectGUI::cutChapter ( )

Cut chapter(s)

Definition at line 2506 of file class.ilObjContentObjectGUI.php.

2506 : void
2507 {
2508 $this->cutItems("chapters");
2509 }

◆ cutItems()

ilObjContentObjectGUI::cutItems ( array  $ids)

Definition at line 2449 of file class.ilObjContentObjectGUI.php.

2449 : void
2450 {
2451 $ilCtrl = $this->ctrl;
2452 $lng = $this->lng;
2453
2454 if (count($ids) == 0) {
2455 $this->tpl->setOnScreenMessage('failure', $lng->txt("no_checkbox"), true);
2456 $ilCtrl->redirect($this, $this->edit_request->getBackCmd());
2457 }
2458
2459 $todel = array(); // delete IDs < 0 (needed for non-js editing)
2460 foreach ($ids as $k => $item) {
2461 if ($item < 0) {
2462 $todel[] = $k;
2463 }
2464 }
2465 foreach ($todel as $k) {
2466 unset($ids[$k]);
2467 }
2468 ilLMObject::clipboardCut($this->lm->getId(), $ids);
2470 $this->tpl->setOnScreenMessage('info', $lng->txt("cont_selected_items_have_been_cut"), true);
2471
2472 $ilCtrl->redirect($this, $this->edit_request->getBackCmd());
2473 }
static clipboardCut(int $a_cont_obj_id, array $a_ids)
Copy a set of chapters/pages into the clipboard.

References $lng, ilLMObject\clipboardCut(), and ilEditClipboard\setAction().

+ Here is the call graph for this function:

◆ deactivateMenuEntry()

ilObjContentObjectGUI::deactivateMenuEntry ( int  $id)

Definition at line 2254 of file class.ilObjContentObjectGUI.php.

2254 : void
2255 {
2257 $this->ctrl->redirect($this, "editMenuProperties");
2258 }

References $id, ILIAS\Repository\ctrl(), and ilLMMenuEditor\writeActive().

+ Here is the call graph for this function:

◆ delete()

ilObjContentObjectGUI::delete ( int  $a_parent_subobj_id = 0,
?int  $page_id = null 
)

confirm deletion screen for free pages (other usages do not apply anymore)

Definition at line 1038 of file class.ilObjContentObjectGUI.php.

1041 : void {
1042 $ids = $page_id === null
1043 ? $this->edit_request->getIds()
1044 : [$page_id];
1045
1046 if (count($ids) == 0) {
1047 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_checkbox"), true);
1048 $this->cancelDelete();
1049 }
1050
1051 if (count($ids) == 1 && $ids[0] == ilTree::POS_FIRST_NODE) {
1052 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("cont_select_item"), true);
1053 $this->cancelDelete();
1054 }
1055
1056 if ($a_parent_subobj_id == 0) {
1057 $this->setTabs("content");
1058 }
1059
1060 if ($a_parent_subobj_id != 0) {
1061 $this->ctrl->setParameterByClass("ilStructureObjectGUI", "backcmd", $this->requested_backcmd);
1062 $this->ctrl->setParameterByClass("ilStructureObjectGUI", "obj_id", $a_parent_subobj_id);
1063 $form_action = $this->ctrl->getFormActionByClass("ilStructureObjectGUI");
1064 } else {
1065 $this->ctrl->setParameter($this, "backcmd", $this->requested_backcmd);
1066 $form_action = $this->ctrl->getFormAction($this);
1067 }
1068
1069 // display confirmation message
1070 $cgui = new ilConfirmationGUI();
1071 $cgui->setFormAction($form_action);
1072 $cgui->setHeaderText($this->lng->txt("info_delete_sure"));
1073 $cgui->setCancel($this->lng->txt("cancel"), "cancelDelete");
1074 $cgui->setConfirm($this->lng->txt("confirm"), "confirmedDelete");
1075
1076 foreach ($ids as $id) {
1077 if ($id != ilTree::POS_FIRST_NODE) {
1078 $obj = new ilLMObject($this->lm, $id);
1079 $caption = $obj->getTitle();
1080
1081 $cgui->addItem("id[]", $id, $caption);
1082 }
1083 }
1084
1085 $this->tpl->setContent($cgui->getHTML());
1086 }
Class ilLMObject.

References ilObjectGUI\$form_action, ilObjectGUI\$id, cancelDelete(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ilTree\POS_FIRST_NODE, and ilObjectGUI\setTabs().

+ Here is the call graph for this function:

◆ deletePage()

ilObjContentObjectGUI::deletePage ( int  $id)

Definition at line 1088 of file class.ilObjContentObjectGUI.php.

1088 : void
1089 {
1090 $this->delete(0, $id);
1091 }

References ilObjectGUI\$id.

◆ deleteTooltip()

ilObjContentObjectGUI::deleteTooltip ( int  $id)

Definition at line 2826 of file class.ilObjContentObjectGUI.php.

2826 : void
2827 {
2828 $tooltip = $this->getTooltip($id);
2829 if ($tooltip === null) {
2830 $this->tpl->setOnScreenMessage("failure", $this->lng->txt("no_checkbox"), true);
2831 $this->ctrl->redirect($this, "showTooltipList");
2832 return;
2833 }
2834
2835 $this->getTooltipTable()->renderDeletionConfirmation(
2836 $this->lng->txt("delete"),
2837 $this->lng->txt("info_delete_sure"),
2838 "confirmedDeleteTooltip",
2839 [$id => (string) $tooltip["tt_id"]]
2840 );
2841 }

References $id, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ doExportHTML()

ilObjContentObjectGUI::doExportHTML ( )
protected

Definition at line 602 of file class.ilObjContentObjectGUI.php.

602 : void
603 {
604 $ot = $this->lm->getObjectProperties()->getPropertyTranslations();
605 $form = $this->buildExportOptionsFormHTML()->withRequest($this->request);
606 $lang = "";
607 if ($ot->getContentTranslationActivated() and !is_null($form->getData())) {
608 $format = explode("_", $form->getData()[0][0]);
609 $lang = ilUtil::stripSlashes($format[1]);
610 }
611 if ($ot->getContentTranslationActivated() and is_null($form->getData())) {
612 $this->addHeaderAction();
613 $this->addLocations(true);
614 $this->setTabs("export");
615 $this->ui->mainTemplate()->setContent($this->ui->renderer()->render($form));
616 return;
617 }
618 $cont_exp = new ilContObjectExport($this->lm, "html", $lang);
619 $cont_exp->buildExportFile();
620 $this->ctrl->redirectByClass(ilExportGUI::class, ilExportGUI::CMD_LIST_EXPORT_FILES);
621 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
const CMD_LIST_EXPORT_FILES
addLocations(bool $a_omit_obj_id=false)
display locator
addHeaderAction()
Add header action menu.

References $form, ilObjectGUI\addHeaderAction(), addLocations(), buildExportOptionsFormHTML(), ilExportGUI\CMD_LIST_EXPORT_FILES, ILIAS\Repository\ctrl(), ilObjectGUI\setTabs(), ilUtil\stripSlashes(), and ILIAS\Repository\ui().

Referenced by showExportOptionsHTML().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ doExportXML()

ilObjContentObjectGUI::doExportXML ( )
protected

Definition at line 582 of file class.ilObjContentObjectGUI.php.

582 : void
583 {
584 $form = $this->buildExportOptionsFormXML()->withRequest($this->request);
585 $format = "";
586 if (!is_null($form->getData())) {
587 $format = explode("_", $form->getData()[0][0]);
588 }
589 if (is_null($form->getData())) {
590 $this->addHeaderAction();
591 $this->addLocations(true);
592 $this->setTabs("export");
593 $this->ui->mainTemplate()->setContent($this->ui->renderer()->render($form));
594 return;
595 }
596 $opt = ilUtil::stripSlashes($format[1]);
597 $cont_exp = new ilContObjectExport($this->lm);
598 $cont_exp->buildExportFile($opt);
599 $this->ctrl->redirectByClass(ilExportGUI::class, ilExportGUI::CMD_LIST_EXPORT_FILES);
600 }

References $form, ilObjectGUI\addHeaderAction(), addLocations(), buildExportOptionsFormXML(), ilExportGUI\CMD_LIST_EXPORT_FILES, ILIAS\Repository\ctrl(), ilObjectGUI\setTabs(), ilUtil\stripSlashes(), and ILIAS\Repository\ui().

+ Here is the call graph for this function:

◆ editExportId()

ilObjContentObjectGUI::editExportId ( int  $id)

Definition at line 2578 of file class.ilObjContentObjectGUI.php.

2578 : void
2579 {
2580 $this->gui->clearAsnyOnloadCode();
2581 $this->gui->modal($this->lng->txt("cont_export_id"))
2582 ->form($this->getExportIdForm($id))
2583 ->send();
2584 }

References $id, and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ editGlossaries()

ilObjContentObjectGUI::editGlossaries ( )

Edit automatically linked glossaries.

Definition at line 3030 of file class.ilObjContentObjectGUI.php.

3030 : void
3031 {
3032 $tpl = $this->tpl;
3033 $ilToolbar = $this->toolbar;
3034 $lng = $this->lng;
3035 $ilCtrl = $this->ctrl;
3036 $ilTabs = $this->tabs;
3037
3038 $this->setTabs();
3039 $ilTabs->setTabActive("settings");
3040 $this->setSubTabs("cont_glossaries");
3041
3042 $ilToolbar->addButton(
3043 $lng->txt("add"),
3044 $ilCtrl->getLinkTarget($this, "showLMGlossarySelector")
3045 );
3046
3047 $table = $this->getGlossariesTable();
3048
3049 if ($table->handleCommand()) {
3050 return;
3051 }
3052
3053 $tpl->setContent($table->render());
3054 }

References $lng, ILIAS\News\Common\Table\$tpl, and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ editHelpMapping()

ilObjContentObjectGUI::editHelpMapping ( int  $id)

Definition at line 2670 of file class.ilObjContentObjectGUI.php.

2670 : void
2671 {
2672 if ($id <= 0 || ilLMObject::_lookupContObjID($id) !== $this->lm->getId()) {
2673 $this->tpl->setOnScreenMessage("failure", $this->lng->txt("no_checkbox"), true);
2674 $this->ctrl->redirect($this, "showExportIDsOverview");
2675 return;
2676 }
2677
2678 $this->gui->clearAsnyOnloadCode();
2679 $this->gui->modal($this->lng->txt("cont_screen_ids"))
2680 ->form($this->getHelpMappingForm($id))
2681 ->send();
2682 }
static _lookupContObjID(int $a_id)
get learning module id for lm object

References $id, ilLMObject\_lookupContObjID(), ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ editMasterLanguage()

ilObjContentObjectGUI::editMasterLanguage ( )

Definition at line 3154 of file class.ilObjContentObjectGUI.php.

3154 : void
3155 {
3156 $ilCtrl = $this->ctrl;
3157
3158 $ilCtrl->setParameter($this, "transl", "-");
3159 if ($this->lang_switch_mode == "short_titles") {
3160 $ilCtrl->redirectByClass("illmeditshorttitlesgui", "");
3161 }
3162 $ilCtrl->redirect($this, "chapters");
3163 }
setParameter(object $a_gui_obj, string $a_parameter, $a_value)
@inheritDoc

◆ editMenuEntry()

ilObjContentObjectGUI::editMenuEntry ( ?ilPropertyFormGUI  $form = null)

Definition at line 2268 of file class.ilObjContentObjectGUI.php.

2268 : void
2269 {
2270 $ilToolbar = $this->toolbar;
2271 $ilCtrl = $this->ctrl;
2272 $ilTabs = $this->tabs;
2273
2274 $this->setTabs();
2275
2276 $ilTabs->setTabActive("settings");
2277 $this->setSubTabs("cont_lm_menu");
2278
2279
2280 if (empty($this->requested_menu_entry)) {
2281 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_menu_entry_id"), true);
2282 $this->ctrl->redirect($this, "editMenuProperties");
2283 }
2284
2285 $ilCtrl->saveParameter($this, array("menu_entry"));
2286 $ilToolbar->addButton(
2287 $this->lng->txt("lm_menu_select_internal_object"),
2288 $ilCtrl->getLinkTarget($this, "showEntrySelector")
2289 );
2290
2291 if (is_null($form)) {
2292 $form = $this->initMenuEntryForm("edit");
2293 }
2294 $this->tpl->setContent($form->getHTML());
2295 }

References ILIAS\Repository\ctrl(), ilPropertyFormGUI\getHTML(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ editMenuEntryFromTable()

ilObjContentObjectGUI::editMenuEntryFromTable ( int  $id)

Definition at line 2260 of file class.ilObjContentObjectGUI.php.

2260 : void
2261 {
2262 $this->requested_menu_entry = $id;
2263 $this->ctrl->setParameter($this, "menu_entry", $id);
2264 $this->editMenuEntry();
2265 }
editMenuEntry(?ilPropertyFormGUI $form=null)

References $id, and ILIAS\Repository\ctrl().

+ Here is the call graph for this function:

◆ editMenuProperties()

ilObjContentObjectGUI::editMenuProperties ( )

Definition at line 961 of file class.ilObjContentObjectGUI.php.

961 : void
962 {
964 $ilTabs = $this->tabs;
965 $ilCtrl = $this->ctrl;
967 $ilToolbar = $this->toolbar;
968
969 $lng->loadLanguageModule("style");
970 $this->setTabs();
971 $ilTabs->setTabActive("settings");
972 $this->setSubTabs("cont_lm_menu");
973
974 $ilToolbar->setFormAction($ilCtrl->getFormAction($this));
975 $ilToolbar->addFormButton($this->lng->txt("add_menu_entry"), "addMenuEntry");
976
977 $form = $this->initMenuForm();
978
979 $table = $this->getMenuItemsTable();
980
981 if ($table->handleCommand()) {
982 return;
983 }
984
985 $tpl->setContent($form->getHTML() . "<br />" . $table->render());
986 }

References ilObjectGUI\$ctrl, $form, ilObjectGUI\$lng, $tabs, ilObjectGUI\$toolbar, ilObjectGUI\$tpl, ilPropertyFormGUI\getHTML(), getMenuItemsTable(), initMenuForm(), ILIAS\Repository\lng(), ilLanguage\loadLanguageModule(), ILIAS\UICore\GlobalTemplate\setContent(), setSubTabs(), and ilObjectGUI\setTabs().

+ Here is the call graph for this function:

◆ editTooltip()

ilObjContentObjectGUI::editTooltip ( int  $id)

Definition at line 2764 of file class.ilObjContentObjectGUI.php.

2764 : void
2765 {
2766 if ($this->getTooltip($id) === null) {
2767 $this->tpl->setOnScreenMessage("failure", $this->lng->txt("no_checkbox"), true);
2768 $this->ctrl->redirect($this, "showTooltipList");
2769 return;
2770 }
2771
2772 $this->gui->clearAsnyOnloadCode();
2773 $this->gui->modal($this->lng->txt("edit"))
2774 ->form($this->getTooltipForm($id))
2775 ->send();
2776 }

References $id, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ export()

ilObjContentObjectGUI::export ( )

Definition at line 1523 of file class.ilObjContentObjectGUI.php.

1523 : void
1524 {
1525 $ot = $this->lm->getObjectProperties()->getPropertyTranslations();
1526 $opt = "";
1527 if ($ot->getContentTranslationActivated()) {
1528 $format = explode("_", $this->edit_request->getFormat());
1529 $opt = ilUtil::stripSlashes($format[1]);
1530 }
1531
1532
1533 $cont_exp = new ilContObjectExport($this->lm);
1534 $cont_exp->buildExportFile($opt);
1535 }

References ilUtil\stripSlashes().

+ Here is the call graph for this function:

◆ exportHTML()

ilObjContentObjectGUI::exportHTML ( )

Definition at line 1563 of file class.ilObjContentObjectGUI.php.

1563 : void
1564 {
1565 $ot = $this->lm->getObjectProperties()->getPropertyTranslations();
1566 $lang = "";
1567 if ($ot->getContentTranslationActivated()) {
1568 $format = explode("_", $this->edit_request->getFormat());
1569 $lang = ilUtil::stripSlashes($format[1]);
1570 }
1571 $cont_exp = new ilContObjectExport($this->lm, "html", $lang);
1572 $cont_exp->buildExportFile();
1573 }

References ilUtil\stripSlashes().

+ Here is the call graph for this function:

◆ filterHelpChapters()

ilObjContentObjectGUI::filterHelpChapters ( )

Definition at line 2571 of file class.ilObjContentObjectGUI.php.

2571 : void
2572 {
2573 $ilCtrl = $this->ctrl;
2574 ilSession::set("help_chap", $this->edit_request->getHelpChap());
2575 $ilCtrl->redirect($this, "showExportIDsOverview");
2576 }

References ilSession\set().

+ Here is the call graph for this function:

◆ filterTooltips()

ilObjContentObjectGUI::filterTooltips ( )

Definition at line 2877 of file class.ilObjContentObjectGUI.php.

2877 : void
2878 {
2879 $ilCtrl = $this->ctrl;
2880
2882 "help_tt_comp",
2883 $this->edit_request->getTooltipComponent()
2884 );
2885 $ilCtrl->redirect($this, "showTooltipList");
2886 }

References ilSession\set().

+ Here is the call graph for this function:

◆ fixTree()

ilObjContentObjectGUI::fixTree ( )

Definition at line 1556 of file class.ilObjContentObjectGUI.php.

1556 : void
1557 {
1558 $this->lm->fixTree();
1559 $this->tpl->setOnScreenMessage('success', $this->lng->txt("cont_tree_fixed"), true);
1560 $this->ctrl->redirect($this, "showMaintenance");
1561 }

References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ fixTreeConfirm()

ilObjContentObjectGUI::fixTreeConfirm ( )

Definition at line 1537 of file class.ilObjContentObjectGUI.php.

1537 : void
1538 {
1539 $this->setTabs();
1540 $this->setContentSubTabs("maintenance");
1541
1542 // display confirmation message
1543 $cgui = new ilConfirmationGUI();
1544 $cgui->setFormAction($this->ctrl->getFormAction($this));
1545 $cgui->setHeaderText($this->lng->txt("cont_fix_tree_confirm"));
1546 $cgui->setCancel($this->lng->txt("cancel"), "showMaintenance");
1547 $cgui->setConfirm($this->lng->txt("cont_fix_tree"), "fixTree");
1548 $issues = $this->lm->checkStructure();
1549 $mess = "";
1550 if (count($issues) > 0) {
1551 $mess = "Found Issues: <br>" . implode("<br>", $issues);
1552 }
1553 $this->tpl->setContent($cgui->getHTML() . $mess);
1554 }

References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ getBlockedUsersMailSignature()

ilObjContentObjectGUI::getBlockedUsersMailSignature ( )
protected

Definition at line 1751 of file class.ilObjContentObjectGUI.php.

1751 : string
1752 {
1753 $link = chr(13) . chr(10) . chr(13) . chr(10);
1754 $link .= $this->lng->txt('cont_blocked_users_mail_link');
1755 $link .= chr(13) . chr(10) . chr(13) . chr(10);
1756 $link .= ilLink::_getLink($this->lm->getRefId());
1757 return rawurlencode(base64_encode($link));
1758 }

References ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ getContextPath()

ilObjContentObjectGUI::getContextPath ( int  $a_endnode_id,
int  $a_startnode_id = 1 
)

Definition at line 1386 of file class.ilObjContentObjectGUI.php.

1389 : string {
1390 $path = "";
1391
1392 $tmpPath = $this->lm_tree->getPathFull($a_endnode_id, $a_startnode_id);
1393
1394 // count -1, to exclude the learning module itself
1395 for ($i = 1; $i < (count($tmpPath) - 1); $i++) {
1396 if ($path != "") {
1397 $path .= " > ";
1398 }
1399
1400 $path .= $tmpPath[$i]["title"];
1401 }
1402
1403 return $path;
1404 }

◆ getExportIdForm()

ilObjContentObjectGUI::getExportIdForm ( int  $id)
protected

Definition at line 2586 of file class.ilObjContentObjectGUI.php.

2587 {
2588 $this->ctrl->setParameter($this, "id", $id);
2589 $form = $this->gui->form([ilLMEditorGUI::class, $this::class], "saveExportId")
2590 ->text(
2591 "exportid",
2592 $this->lng->txt("cont_export_id"),
2593 "",
2595 $this->lm->getId(),
2596 $id,
2598 )
2599 );
2600
2601 return $form;
2602 }
static getExportId(int $a_lm_id, int $a_lmobj_id, string $a_type="pg")
static _lookupType(int $a_obj_id, int $a_lm_id=0)

References $id, ilLMObject\_lookupType(), ILIAS\Repository\ctrl(), ilLMObject\getExportId(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ getGlossariesTable()

ilObjContentObjectGUI::getGlossariesTable ( )
protected

Definition at line 3056 of file class.ilObjContentObjectGUI.php.

3057 {
3058 return $this->gui->editing()->glossariesTableBuilder(
3059 $this->lm,
3060 $this,
3061 "editGlossaries"
3062 )->getTable();
3063 }

References ILIAS\Repository\Table\TableAdapterGUI\getTable().

+ Here is the call graph for this function:

◆ getHelpMappingForm()

ilObjContentObjectGUI::getHelpMappingForm ( int  $id)
protected

Definition at line 2684 of file class.ilObjContentObjectGUI.php.

2685 {
2686 $this->ctrl->setParameter($this, "edit_id", $id);
2687 $screen_ids = $this->help->internal()->domain()->map()->getScreenIdsOfChapter($id);
2688
2689 return $this->gui->form([ilLMEditorGUI::class, $this::class], "saveHelpMapping")
2690 ->textarea(
2691 "screen_ids",
2692 $this->lng->txt("cont_screen_ids"),
2693 "",
2694 implode("\n", $screen_ids)
2695 );
2696 }

References $id, ILIAS\Repository\ctrl(), ILIAS\Repository\help(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ getHelpMappingTable()

ilObjContentObjectGUI::getHelpMappingTable ( )
protected

Definition at line 2561 of file class.ilObjContentObjectGUI.php.

2562 {
2563 return $this->gui->editing()->helpMappingTableBuilder(
2564 $this->lm,
2565 (int) ilSession::get("help_chap"),
2566 $this,
2567 "showExportIDsOverview"
2568 )->getTable();
2569 }
static get(string $a_var)

References ilSession\get(), and ILIAS\Repository\Table\TableAdapterGUI\getTable().

+ Here is the call graph for this function:

◆ getLayoutOption()

static ilObjContentObjectGUI::getLayoutOption ( string  $a_txt,
string  $a_var,
string  $a_def_option = "" 
)
static

Definition at line 2893 of file class.ilObjContentObjectGUI.php.

2898 global $DIC;
2899
2900 $im_tag = "";
2901
2902 $lng = $DIC->language();
2903
2904 // default layout
2905 $layout = new ilRadioGroupInputGUI($a_txt, $a_var);
2906 if ($a_def_option != "") {
2907 if (is_file($im = ilUtil::getImagePath("layout_" . $a_def_option . ".png"))) {
2908 $im_tag = ilUtil::img($im, $a_def_option);
2909 }
2910 $layout->addOption(new ilRadioOption("<table><tr><td>" . $im_tag . "</td><td><strong>" .
2911 $lng->txt("cont_lm_default_layout") .
2912 "</strong>: " . $lng->txt("cont_layout_" . $a_def_option) .
2913 "</td></tr></table>", ""));
2914 }
2915 foreach (ilObjContentObject::getAvailableLayouts() as $l) {
2916 $im_tag = "";
2917 if (is_file($im = ilUtil::getImagePath("layout_" . $l . ".png"))) {
2918 $im_tag = ilUtil::img($im, $l);
2919 }
2920 $layout->addOption(new ilRadioOption("<table><tr><td style='padding: 0px 5px 5px;'>" .
2921 $im_tag . "</td><td style='padding:5px;'><strong>" . $lng->txt("cont_layout_" . $l) . "</strong>: " .
2922 $lng->txt("cont_layout_" . $l . "_desc") . "</td></tr></table>", $l));
2923 }
2924
2925 return $layout;
2926 }
static getAvailableLayouts()
get all available lm layouts
This class represents a property in a property form.
This class represents an option in a radio group.
static getImagePath(string $image_name, string $module_path="", string $mode="output", bool $offline=false)
get image path (for images located in a template directory)
static img(string $a_src, ?string $a_alt=null, $a_width="", $a_height="", $a_border=0, $a_id="", $a_class="")
Build img tag.

Referenced by ilStructureObjectGUI\initSetPageLayoutForm().

+ Here is the caller graph for this function:

◆ getMenuEntryData()

ilObjContentObjectGUI::getMenuEntryData ( int  $id)
protected

Definition at line 2190 of file class.ilObjContentObjectGUI.php.

2190 : ?array
2191 {
2192 $this->__initLMMenuEditor();
2193 foreach ($this->lmme_obj->getMenuEntries() as $entry) {
2194 if ((int) $entry["id"] === $id) {
2195 return $entry;
2196 }
2197 }
2198 return null;
2199 }

References $id.

◆ getMenuItemsTable()

ilObjContentObjectGUI::getMenuItemsTable ( )
protected

Definition at line 2180 of file class.ilObjContentObjectGUI.php.

2181 {
2182 $this->__initLMMenuEditor();
2183 return $this->gui->editing()->menuItemsTableBuilder(
2184 $this->lmme_obj->getMenuEntries(),
2185 $this,
2186 "editMenuProperties"
2187 )->getTable();
2188 }

Referenced by editMenuProperties().

+ Here is the caller graph for this function:

◆ getMultiLangHeader()

static ilObjContentObjectGUI::getMultiLangHeader ( int  $a_lm_id,
object  $a_gui_class,
string  $a_mode = "" 
)
static

Definition at line 1153 of file class.ilObjContentObjectGUI.php.

1157 : string {
1158 global $DIC;
1159
1160 $lng = $DIC->language();
1161 $ilCtrl = $DIC->ctrl();
1162 $ilDB = $DIC->database();
1163
1165 ->learningModule()
1166 ->internal()
1167 ->gui()
1168 ->editing()
1169 ->request();
1170
1171 $ui_renderer = $DIC->ui()->renderer();
1172 $ui_factory = $DIC->ui()->factory();
1173
1176
1177 $ml_head = "";
1178
1179 // multi language
1180 $ot = (new TranslationsRepository($ilDB))->getFor($a_lm_id);
1181 if ($ot->getContentTranslationActivated()) {
1182 $ilCtrl->setParameter($a_gui_class, "lang_switch_mode", $a_mode);
1183 $lng->loadLanguageModule("meta");
1184
1185 // info
1186 $ml_gui = new ilPageMultiLangGUI("lm", $a_lm_id);
1187 $ml_head = $ml_gui->getMultiLangInfo($requested_transl);
1188
1189 $actions = [];
1190
1191 // language switch
1192 $entries = false;
1193 if (!in_array($requested_transl, array("", "-"))) {
1194 $l = $ot->getBaseLanguage();
1195 $actions[] = $ui_factory->link()->standard(
1196 $lng->txt("cont_edit_language_version") . ": " .
1197 $lng->txt("meta_l_" . $l),
1198 $ilCtrl->getLinkTarget($a_gui_class, "editMasterLanguage")
1199 );
1200 $entries = true;
1201 }
1202
1203 foreach ($ot->getLanguages() as $al => $lang) {
1204 if ($requested_transl != $al &&
1205 $al != $ot->getBaseLanguage()) {
1206 $ilCtrl->setParameter($a_gui_class, "totransl", $al);
1207 $actions[] = $ui_factory->link()->standard(
1208 $lng->txt("cont_edit_language_version") . ": " .
1209 $lng->txt("meta_l_" . $al),
1210 $ilCtrl->getLinkTarget($a_gui_class, "switchToLanguage")
1211 );
1212 $ilCtrl->setParameter($a_gui_class, "totransl", $requested_totransl);
1213 }
1214 $entries = true;
1215 }
1216
1217 if ($entries) {
1218 $dd = $ui_factory->dropdown()->standard($actions)->withLabel($lng->txt("actions"));
1219
1220 $ml_head = '<div class="ilFloatLeft">' . $ml_head . '</div><div style="margin: 5px 0;" class="small ilRight">' . $ui_renderer->render($dd) . "</div>";
1221 }
1222 $ilCtrl->setParameter($a_gui_class, "lang_switch_mode", "");
1223 }
1224
1225 return "<div class='ilClearFloat'>" . $ml_head . "</div>";
1226 }
UIFactory $ui_factory
UIRenderer $ui_renderer
Page multilinguality GUI class.

References ilObjectGUI\$lng, $requested_totransl, $requested_transl, ilObjectGUI\$ui_factory, ilObjectGUI\$ui_renderer, ilLanguage\loadLanguageModule(), and ilLanguage\txt().

Referenced by ILIAS\LearningModule\Editing\EditSubObjectsGUI\list(), and ilLMEditShortTitlesGUI\listShortTitles().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getPropertiesFormValues()

ilObjContentObjectGUI::getPropertiesFormValues ( )

Get values for properties form.

Definition at line 776 of file class.ilObjContentObjectGUI.php.

776 : void
777 {
778 $ilUser = $this->user;
779
780 $values = array();
781
782 $title = $this->lm->getTitle();
783 $description = $this->lm->getLongDescription();
784 $ot = $this->lm->getObjectProperties()->getPropertyTranslations();
785 if ($ot->getContentTranslationActivated()) {
786 $title = $ot->getDefaultTitle();
787 $description = $ot->getDefaultDescription();
788 }
789
790 $values["title"] = $title;
791 $values["description"] = $description;
792 if (!$this->lm->getOfflineStatus()) {
793 $values["cobj_online"] = true;
794 }
795 //$values["lm_layout"] = $this->lm->getLayout();
796 $values["lm_pg_header"] = $this->lm->getPageHeader();
797 if ($this->lm->isActiveNumbering()) {
798 $values["cobj_act_number"] = true;
799 }
800 $values["toc_mode"] = $this->lm->getTOCMode();
801 if ($this->lm->publicNotes()) {
802 $values["cobj_pub_notes"] = true;
803 }
804 if ($this->lm->cleanFrames()) {
805 $values["cobj_clean_frames"] = true;
806 }
807 //$values["layout_per_page"] = $this->lm->getLayoutPerPage();
808 $values["rating"] = $this->lm->hasRating();
809 $values["rating_pages"] = $this->lm->hasRatingPages();
810 $values["disable_def_feedback"] = $this->lm->getDisableDefaultFeedback();
811 $values["progr_icons"] = $this->lm->getProgressIcons();
812 $values["store_tries"] = (string) (int) $this->lm->getStoreTries();
813 $values["restrict_forw_nav"] = $this->lm->getRestrictForwardNavigation();
814
815 $values["notification_blocked_users"] = ilNotification::hasNotification(
817 $ilUser->getId(),
818 $this->lm->getId()
819 );
820
821 $values["cont_show_info_tab"] = $this->object->isInfoEnabled();
822 $this->form->setValuesByArray($values, true);
823 }
static hasNotification(int $type, int $user_id, int $id)
Check notification status for object and user.
form(?array $class_path, string $cmd, string $submit_caption="")

References ilObjectGUI\$user, ILIAS\Repository\form(), ilNotification\hasNotification(), and ilNotification\TYPE_LM_BLOCKED_USERS.

Referenced by properties().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getTooltip()

ilObjContentObjectGUI::getTooltip ( int  $id)
protected

Definition at line 2752 of file class.ilObjContentObjectGUI.php.

2752 : ?array
2753 {
2754 $component = (string) ilSession::get("help_tt_comp");
2755 foreach ($this->help->internal()->domain()->tooltips()->getAllTooltips($component) as $tooltip) {
2756 if ((int) $tooltip["id"] === $id) {
2757 return $tooltip;
2758 }
2759 }
2760
2761 return null;
2762 }

References $id, ilSession\get(), and ILIAS\Repository\help().

+ Here is the call graph for this function:

◆ getTooltipForm()

ilObjContentObjectGUI::getTooltipForm ( int  $id)
protected

Definition at line 2778 of file class.ilObjContentObjectGUI.php.

2779 {
2780 $tooltip = $this->getTooltip($id) ?? ["tt_id" => "", "text" => ""];
2781 $this->ctrl->setParameter($this, "edit_id", $id);
2782
2783 return $this->gui->form([ilLMEditorGUI::class, $this::class], "saveTooltip")
2784 ->text(
2785 "tt_id",
2786 $this->lng->txt("help_tooltip_id"),
2787 "",
2788 (string) $tooltip["tt_id"],
2789 200
2790 )
2791 ->textarea(
2792 "text",
2793 $this->lng->txt("help_tt_text"),
2794 "",
2795 (string) $tooltip["text"]
2796 );
2797 }

References $id, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ getTooltipTable()

ilObjContentObjectGUI::getTooltipTable ( )
protected

Definition at line 2743 of file class.ilObjContentObjectGUI.php.

2744 {
2745 return $this->gui->helpTooltipTableBuilder(
2746 (string) ilSession::get("help_tt_comp"),
2747 $this,
2748 "showTooltipList"
2749 )->getTable();
2750 }

References ilSession\get(), and ILIAS\Repository\Table\TableAdapterGUI\getTable().

+ Here is the call graph for this function:

◆ initMenuEntryForm()

ilObjContentObjectGUI::initMenuEntryForm ( string  $a_mode = "edit")

Definition at line 2096 of file class.ilObjContentObjectGUI.php.

2097 {
2098 $lng = $this->lng;
2099 $ilCtrl = $this->ctrl;
2100
2101 $form = new ilPropertyFormGUI();
2102
2103 // title
2104 $ti = new ilTextInputGUI($this->lng->txt("lm_menu_entry_title"), "title");
2105 $ti->setMaxLength(255);
2106 $ti->setSize(40);
2107 $ti->setRequired(true);
2108 $form->addItem($ti);
2109
2110 // target
2111 $ta = new ilTextInputGUI($this->lng->txt("lm_menu_entry_target"), "target");
2112 $ta->setMaxLength(255);
2113 $ta->setSize(40);
2114 $ta->setRequired(true);
2115 $form->addItem($ta);
2116
2117 if ($a_mode == "edit") {
2118 $this->__initLMMenuEditor();
2119 $this->lmme_obj->readEntry($this->requested_menu_entry);
2120 $ti->setValue($this->lmme_obj->getTitle());
2121 $ta->setValue($this->lmme_obj->getTarget());
2122 }
2123
2124 if ($this->requested_link_ref_id > 0) {
2125 $link_ref_id = $this->requested_link_ref_id;
2126 $obj_type = ilObject::_lookupType($link_ref_id, true);
2127 $obj_id = ilObject::_lookupObjectId($link_ref_id);
2129
2130 $target_link = $obj_type . "_" . $link_ref_id;
2131 $ti->setValue($title);
2132 $ta->setValue($target_link);
2133
2134 // link ref id
2135 $hi = new ilHiddenInputGUI("link_ref_id");
2136 $hi->setValue($link_ref_id);
2137 $form->addItem($hi);
2138 }
2139
2140
2141 // save and cancel commands
2142 if ($a_mode == "create") {
2143 $form->addCommandButton("saveMenuEntry", $lng->txt("save"));
2144 $form->addCommandButton("editMenuProperties", $lng->txt("cancel"));
2145 $form->setTitle($lng->txt("lm_menu_new_entry"));
2146 } else {
2147 $form->addCommandButton("updateMenuEntry", $lng->txt("save"));
2148 $form->addCommandButton("editMenuProperties", $lng->txt("cancel"));
2149 $form->setTitle($lng->txt("lm_menu_edit_entry"));
2150 }
2151
2152 $form->setFormAction($ilCtrl->getFormAction($this));
2153
2154 return $form;
2155 }
setFormAction(string $a_formaction)
This class represents a hidden form property in a property form.
static _lookupObjectId(int $ref_id)
static _lookupType(int $id, bool $reference=false)
This class represents a property form user interface.
addCommandButton(string $a_cmd, string $a_text, string $a_id="")
This class represents a text property in a property form.

References $lng, ilObject\_lookupObjectId(), ilObject\_lookupTitle(), ilObject\_lookupType(), ilPropertyFormGUI\addCommandButton(), ilPropertyFormGUI\addItem(), ILIAS\Repository\lng(), ilFormGUI\setFormAction(), and ilPropertyFormGUI\setTitle().

+ Here is the call graph for this function:

◆ initMenuForm()

ilObjContentObjectGUI::initMenuForm ( )

Definition at line 919 of file class.ilObjContentObjectGUI.php.

920 {
922 $ilCtrl = $this->ctrl;
923
924 $form = new ilPropertyFormGUI();
925
926 // enable menu
927 $menu = new ilCheckboxInputGUI($this->lng->txt("cont_active"), "cobj_act_lm_menu");
928 $menu->setChecked($this->lm->isActiveLMMenu());
929 $form->addItem($menu);
930
931 // toc
932 /*
933 $toc = new ilCheckboxInputGUI($this->lng->txt("cont_toc"), "cobj_act_toc");
934
935 $toc->setChecked($this->lm->isActiveTOC());
936 $form->addItem($toc);*/
937
938 // print view
939 $print = new ilCheckboxInputGUI($this->lng->txt("cont_print_view"), "cobj_act_print");
940 $print->setChecked($this->lm->isActivePrintView());
941 $form->addItem($print);
942
943 // prevent glossary appendix
944 $glo = new ilCheckboxInputGUI($this->lng->txt("cont_print_view_pre_glo"), "cobj_act_print_prev_glo");
945 $glo->setChecked($this->lm->isActivePreventGlossaryAppendix());
946 $print->addSubItem($glo);
947
948 // hide header and footer in print view
949 $hhfp = new ilCheckboxInputGUI($this->lng->txt("cont_hide_head_foot_print"), "hide_head_foot_print");
950 $hhfp->setChecked($this->lm->getHideHeaderFooterPrint());
951 $print->addSubItem($hhfp);
952
953 $form->addCommandButton("saveMenuProperties", $lng->txt("save"));
954
955 $form->setTitle($lng->txt("cont_lm_menu"));
956 $form->setFormAction($ilCtrl->getFormAction($this));
957
958 return $form;
959 }
This class represents a checkbox property in a property form.

References ilObjectGUI\$ctrl, $form, ilObjectGUI\$lng, ilPropertyFormGUI\addCommandButton(), ilPropertyFormGUI\addItem(), ILIAS\Repository\lng(), ilFormGUI\setFormAction(), ilPropertyFormGUI\setTitle(), and ilLanguage\txt().

Referenced by editMenuProperties(), and saveMenuProperties().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initPropertiesForm()

ilObjContentObjectGUI::initPropertiesForm ( )

Init properties form.

Definition at line 648 of file class.ilObjContentObjectGUI.php.

648 : void
649 {
650 $obj_service = $this->object_service;
651
652 $ilCtrl = $this->ctrl;
655
656 $this->form = new ilPropertyFormGUI();
657
658 // title
659 $ti = new ilTextInputGUI($lng->txt("title"), "title");
660 $ti->setRequired(true);
661 $this->form->addItem($ti);
662
663 // description
664 $ta = new ilTextAreaInputGUI($lng->txt("desc"), "description");
665 $this->form->addItem($ta);
666
667 $lng->loadLanguageModule("rep");
668 $section = new ilFormSectionHeaderGUI();
669 $section->setTitle($this->lng->txt('rep_activation_availability'));
670 $this->form->addItem($section);
671
672 // online
673 $online = new ilCheckboxInputGUI($lng->txt("cont_online"), "cobj_online");
674 $this->form->addItem($online);
675
676 // presentation
677 $section = new ilFormSectionHeaderGUI();
678 $section->setTitle($this->lng->txt('cont_presentation'));
679 $this->form->addItem($section);
680
681 // tile image
682 $obj_service->commonSettings()->legacyForm($this->form, $this->lm)->addTileImage();
683
684 // page header
685 $page_header = new ilSelectInputGUI($lng->txt("cont_page_header"), "lm_pg_header");
686 $option = array("st_title" => $this->lng->txt("cont_st_title"),
687 "pg_title" => $this->lng->txt("cont_pg_title"),
688 "none" => $this->lng->txt("cont_none"));
689 $page_header->setOptions($option);
690 $this->form->addItem($page_header);
691
692 // chapter numeration
693 $chap_num = new ilCheckboxInputGUI($lng->txt("cont_act_number"), "cobj_act_number");
694 $this->form->addItem($chap_num);
695
696 // toc mode
697 $toc_mode = new ilSelectInputGUI($lng->txt("cont_toc_mode"), "toc_mode");
698 $option = array("chapters" => $this->lng->txt("cont_chapters_only"),
699 "pages" => $this->lng->txt("cont_chapters_and_pages"));
700 $toc_mode->setOptions($option);
701 $this->form->addItem($toc_mode);
702
703 // show progress icons
704 $progr_icons = new ilCheckboxInputGUI($lng->txt("cont_progress_icons"), "progr_icons");
705 $progr_icons->setInfo($this->lng->txt("cont_progress_icons_info"));
706 $this->form->addItem($progr_icons);
707
708 $this->reading_time_gui->addSettingToForm($this->form);
709
710 // self assessment
711 $section = new ilFormSectionHeaderGUI();
712 $section->setTitle($this->lng->txt('cont_self_assessment'));
713 $this->form->addItem($section);
714
715 // tries
716 $radg = new ilRadioGroupInputGUI($lng->txt("cont_tries"), "store_tries");
717 $radg->setValue("0");
718 $op1 = new ilRadioOption($lng->txt("cont_tries_reset_on_visit"), "0", $lng->txt("cont_tries_reset_on_visit_info"));
719 $radg->addOption($op1);
720 $op2 = new ilRadioOption($lng->txt("cont_tries_store"), "1", $lng->txt("cont_tries_store_info"));
721 $radg->addOption($op2);
722 $this->form->addItem($radg);
723
724 // restrict forward navigation
725 $qfeed = new ilCheckboxInputGUI($lng->txt("cont_restrict_forw_nav"), "restrict_forw_nav");
726 $qfeed->setInfo($this->lng->txt("cont_restrict_forw_nav_info"));
727 $this->form->addItem($qfeed);
728
729 // notification
730 $not = new ilCheckboxInputGUI($lng->txt("cont_notify_on_blocked_users"), "notification_blocked_users");
731 $not->setInfo($this->lng->txt("cont_notify_on_blocked_users_info"));
732 $qfeed->addSubItem($not);
733
734 // disable default feedback for questions
735 $qfeed = new ilCheckboxInputGUI($lng->txt("cont_disable_def_feedback"), "disable_def_feedback");
736 $qfeed->setInfo($this->lng->txt("cont_disable_def_feedback_info"));
737 $this->form->addItem($qfeed);
738
739 // additional features
740 $section = new ilFormSectionHeaderGUI();
741 $section->setTitle($this->lng->txt('obj_features'));
742 $this->form->addItem($section);
743
744 // public notes
745 if (!$ilSetting->get('disable_comments')) {
746 $this->lng->loadLanguageModule("notes");
747 $pub_nodes = new ilCheckboxInputGUI($lng->txt("notes_comments"), "cobj_pub_notes");
748 $pub_nodes->setInfo($this->lng->txt("cont_lm_comments_desc"));
749 $this->form->addItem($pub_nodes);
750 }
751
752 // rating
753 $this->lng->loadLanguageModule('rating');
754 $rate = new ilCheckboxInputGUI($this->lng->txt('rating_activate_rating'), 'rating');
755 $rate->setInfo($this->lng->txt('rating_activate_rating_info'));
756 $this->form->addItem($rate);
757 $ratep = new ilCheckboxInputGUI($this->lng->txt('lm_activate_rating'), 'rating_pages');
758 $this->form->addItem($ratep);
759
760 $this->form->setTitle($lng->txt("cont_lm_properties"));
761 $this->form->addCommandButton("saveProperties", $lng->txt("save"));
762 $this->form->setFormAction($ilCtrl->getFormAction($this));
763
765 $this->object->getId(),
766 $this->form,
767 [
769 ]
770 );
771 }
This class represents a section header in a property form.
ilObjectService $object_service
ilSetting $settings
static initServiceSettingsForm(int $obj_id, ilPropertyFormGUI $form, array $services)
This class represents a selection list property in a property form.
This class represents a text area property in a property form.
global $ilSetting
Definition: privfeed.php:26

References ilObjectGUI\$ctrl, $ilSetting, ilObjectGUI\$lng, ilObjectGUI\$object_service, ilObjectGUI\$settings, ILIAS\Repository\form(), ilObjectServiceSettingsGUI\INFO_TAB_VISIBILITY, ilObjectServiceSettingsGUI\initServiceSettingsForm(), ILIAS\Repository\lng(), ilLanguage\loadLanguageModule(), ILIAS\Repository\object(), and ilLanguage\txt().

Referenced by properties(), and saveProperties().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initSetPageLayoutForm()

ilObjContentObjectGUI::initSetPageLayoutForm ( array  $ids = [])

Definition at line 2970 of file class.ilObjContentObjectGUI.php.

2970 : void
2971 {
2972 $lng = $this->lng;
2973 $ilCtrl = $this->ctrl;
2974
2975 $this->form = new ilPropertyFormGUI();
2976
2977 if (count($ids) === 0) {
2978 $ids = $this->edit_request->getIds();
2979 }
2980 foreach ($ids as $id) {
2981 $hi = new ilHiddenInputGUI("id[]");
2982 $hi->setValue($id);
2983 $this->form->addItem($hi);
2984 }
2985 $layout = self::getLayoutOption(
2986 $lng->txt("cont_layout"),
2987 "layout",
2988 $this->lm->getLayout()
2989 );
2990 $this->form->addItem($layout);
2991
2992 $this->form->addCommandButton("savePageLayout", $lng->txt("save"));
2993 $this->form->addCommandButton("pages", $lng->txt("cancel"));
2994
2995 $this->form->setTitle($lng->txt("cont_set_layout"));
2996 $this->form->setFormAction($ilCtrl->getFormAction($this));
2997 }
static getLayoutOption(string $a_txt, string $a_var, string $a_def_option="")

References $id, $lng, and ILIAS\Repository\form().

+ Here is the call graph for this function:

◆ learningProgress()

ilObjContentObjectGUI::learningProgress ( )
protected

Learning progress.

Definition at line 3185 of file class.ilObjContentObjectGUI.php.

3185 : void
3186 {
3187 $this->ctrl->redirectByClass(array('illearningprogressgui'), '');
3188 }

References ILIAS\Repository\ctrl().

+ Here is the call graph for this function:

◆ listBlockedUsers()

ilObjContentObjectGUI::listBlockedUsers ( )

Definition at line 1663 of file class.ilObjContentObjectGUI.php.

1663 : void
1664 {
1665 $tpl = $this->tpl;
1666
1667 $this->setTabs("questions");
1668 $this->setQuestionsSubTabs("blocked_users");
1669
1670 $table = $this->gui->blockedUsersTableBuilder(
1671 $this->lm->getRefId(),
1672 $this,
1673 "listBlockedUsers"
1674 )->getTable();
1675 if ($table->handleCommand()) {
1676 return;
1677 }
1678 $tpl->setContent($table->render());
1679 }

References ILIAS\News\Common\Table\$tpl, and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ listLinks()

ilObjContentObjectGUI::listLinks ( )

List all broken links.

Definition at line 1262 of file class.ilObjContentObjectGUI.php.

1262 : void
1263 {
1264 $tpl = $this->tpl;
1265
1266 $this->setTabs();
1267 $this->setContentSubTabs("internal_links");
1268
1269 $table = $this->gui->linksTableBuilder(
1270 $this->lm->getId(),
1271 $this->lm->getType(),
1272 $this,
1273 "listLinks"
1274 )->getTable();
1275
1276 if ($table->handleCommand()) {
1277 return;
1278 }
1279
1280 $tpl->setContent($table->render());
1281 }

References ILIAS\News\Common\Table\$tpl, and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ listQuestions()

ilObjContentObjectGUI::listQuestions ( )

Definition at line 1628 of file class.ilObjContentObjectGUI.php.

1628 : void
1629 {
1630 $tpl = $this->tpl;
1631
1632 $this->setTabs("questions");
1633 $this->setQuestionsSubTabs("question_stats");
1634
1635 $table = $this->gui->questionStatisticsTableBuilder(
1636 $this->lm->getId(),
1637 $this,
1638 "listQuestions"
1639 )->getTable();
1640 if ($table->handleCommand()) {
1641 return;
1642 }
1643 $tpl->setContent($table->render());
1644 }

References ILIAS\News\Common\Table\$tpl, and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ listQuestionUsages()

ilObjContentObjectGUI::listQuestionUsages ( )

Definition at line 1646 of file class.ilObjContentObjectGUI.php.

1646 : void
1647 {
1648 $tpl = $this->tpl;
1649
1650 $this->setTabs("questions");
1651 $this->setQuestionsSubTabs("question_usage");
1652
1653 $table_builder = new QuestionUsageTableBuilder(
1654 $this,
1655 'listQuestionUsages',
1656 $this->lm->getId()
1657 );
1658 $table = $table_builder->getTable();
1659 $tpl->setContent($table->render());
1660 }

References ILIAS\News\Common\Table\$tpl, and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ moveChapter()

ilObjContentObjectGUI::moveChapter ( int  $a_parent_subobj_id = 0)

move a single chapter (selection)

Definition at line 1453 of file class.ilObjContentObjectGUI.php.

1453 : void
1454 {
1455 $ids = $this->edit_request->getIds();
1456 if (count($ids) == 0) {
1457 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_checkbox"));
1458 if ($a_parent_subobj_id == 0) {
1459 $this->ctrl->redirect($this, "chapters");
1460 }
1461 return;
1462 }
1463 if (count($ids) > 1) {
1464 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("cont_select_max_one_item"));
1465 if ($a_parent_subobj_id == 0) {
1466 $this->ctrl->redirect($this, "chapters");
1467 }
1468 return;
1469 }
1470
1471 if (count($ids) == 1 && $ids[0] == ilTree::POS_FIRST_NODE) {
1472 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("cont_select_item"));
1473 if ($a_parent_subobj_id == 0) {
1474 $this->ctrl->redirect($this, "chapters");
1475 }
1476 }
1477
1478 // SAVE POST VALUES
1479 ilEditClipboard::storeContentObject("st", $ids[0], "move");
1480
1481 $this->tpl->setOnScreenMessage('info', $this->lng->txt("cont_chap_select_target_now"), true);
1482
1483 if ($a_parent_subobj_id == 0) {
1484 $this->ctrl->redirect($this, "chapters");
1485 }
1486 }
static storeContentObject(string $a_type, int $a_id, string $a_action="cut")

References ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ilTree\POS_FIRST_NODE, and ilEditClipboard\storeContentObject().

+ Here is the call graph for this function:

◆ movePage()

ilObjContentObjectGUI::movePage ( int  $id = 0)

Definition at line 1498 of file class.ilObjContentObjectGUI.php.

1498 : void
1499 {
1500 $ids = $id > 0 ? [$id] : $this->edit_request->getIds();
1501 if (count($ids) == 0) {
1502 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_checkbox"), true);
1503 $this->ctrl->redirect($this, "pages");
1504 }
1505
1506 $this->tpl->setOnScreenMessage('info', $this->lng->txt("cont_selected_items_have_been_cut"), true);
1507
1508 ilLMObject::clipboardCut($this->lm->getId(), $ids);
1510
1511 $this->ctrl->redirect($this, "pages");
1512 }

References $id, ilLMObject\clipboardCut(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ilEditClipboard\setAction().

+ Here is the call graph for this function:

◆ normalizeBlockedUserIds()

ilObjContentObjectGUI::normalizeBlockedUserIds ( string|array  $user_q_ids)
protected

Definition at line 1743 of file class.ilObjContentObjectGUI.php.

1743 : array
1744 {
1745 if (is_string($user_q_ids)) {
1746 $user_q_ids = $user_q_ids === "" ? [] : [$user_q_ids];
1747 }
1748 return $user_q_ids;
1749 }

◆ pages()

ilObjContentObjectGUI::pages ( )

Definition at line 1228 of file class.ilObjContentObjectGUI.php.

1228 : void
1229 {
1230 $tpl = $this->tpl;
1231 $ilToolbar = $this->toolbar;
1232 $ilCtrl = $this->ctrl;
1233 $lng = $this->lng;
1234
1235 $this->setTabs();
1236 $this->setContentSubTabs("pages");
1237
1238 $ilCtrl->setParameter($this, "backcmd", "pages");
1239 $ilCtrl->setParameterByClass("illmpageobjectgui", "new_type", "pg");
1240 $ilToolbar->addButton(
1241 $lng->txt("pg_add"),
1242 $ilCtrl->getLinkTargetByClass("illmpageobjectgui", "create")
1243 );
1244 $ilCtrl->setParameterByClass("illmpageobjectgui", "new_type", "");
1245
1246 $table = $this->gui->editing()->pagesTableBuilder(
1247 $this->lm,
1248 $this,
1249 "pages"
1250 )->getTable();
1251
1252 if ($table->handleCommand()) {
1253 return;
1254 }
1255
1256 $tpl->setContent($table->render());
1257 }

References $lng, ILIAS\News\Common\Table\$tpl, and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ pasteChapter()

ilObjContentObjectGUI::pasteChapter ( )

Definition at line 1493 of file class.ilObjContentObjectGUI.php.

1493 : void
1494 {
1495 $this->insertChapterClip();
1496 }

◆ proceedDragDrop()

ilObjContentObjectGUI::proceedDragDrop ( )

Definition at line 1004 of file class.ilObjContentObjectGUI.php.

1004 : void
1005 {
1006 $ilCtrl = $this->ctrl;
1007
1009 $this->lm->executeDragDrop(
1010 $req->getHFormPar("source_id"),
1011 $req->getHFormPar("target_id"),
1012 $req->getHFormPar("fc"),
1013 $req->getHFormPar("as_subitem")
1014 );
1015 $ilCtrl->redirect($this, "chapters");
1016 }

References ilObjectGUI\$ctrl, $edit_request, and XapiProxy\$req.

◆ properties()

ilObjContentObjectGUI::properties ( )

edit properties form

Definition at line 626 of file class.ilObjContentObjectGUI.php.

626 : void
627 {
629
630 $lng->loadLanguageModule("style");
631 $this->setTabs("settings");
632 $this->setSubTabs("settings");
633
634 // lm properties
635 $this->initPropertiesForm();
637
638 // Edit ecs export settings
639 $ecs = new ilECSLearningModuleSettings($this->lm);
640 $ecs->addSettingsToForm($this->form, 'lm');
641
642 $this->tpl->setContent($this->form->getHTML());
643 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
initPropertiesForm()
Init properties form.
getPropertiesFormValues()
Get values for properties form.

References ilObjectGUI\$lng, ILIAS\Repository\form(), getPropertiesFormValues(), initPropertiesForm(), ilLanguage\loadLanguageModule(), setSubTabs(), and ilObjectGUI\setTabs().

Referenced by ilObjLearningModuleGUI\view().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ redrawHeaderAction()

ilObjContentObjectGUI::redrawHeaderAction ( )

Definition at line 3176 of file class.ilObjContentObjectGUI.php.

3176 : void
3177 {
3178 // #12281
3179 parent::redrawHeaderActionObject();
3180 }

◆ removeLMGlossary()

ilObjContentObjectGUI::removeLMGlossary ( )

Definition at line 3140 of file class.ilObjContentObjectGUI.php.

3140 : void
3141 {
3142 $ilCtrl = $this->ctrl;
3143 $lng = $this->lng;
3144
3145 foreach ($this->getGlossariesTable()->getItemIds() as $glo_id) {
3146 $this->lm->removeAutoGlossary((int) $glo_id);
3147 }
3148 $this->lm->update();
3149
3150 $this->tpl->setOnScreenMessage('success', $lng->txt("msg_obj_modified"), true);
3151 $ilCtrl->redirect($this, "editGlossaries");
3152 }

References $lng.

◆ resetNumberOfTries()

ilObjContentObjectGUI::resetNumberOfTries ( string|array  $user_q_ids = [])

Definition at line 1681 of file class.ilObjContentObjectGUI.php.

1681 : void
1682 {
1683 $lng = $this->lng;
1684 $ilCtrl = $this->ctrl;
1685
1686 $user_q_ids = $this->normalizeBlockedUserIds($user_q_ids);
1687 if (count($user_q_ids) > 0) {
1688 foreach ($user_q_ids as $uqid) {
1689 $uqid = explode(":", $uqid);
1690 ilPageQuestionProcessor::resetTries((int) $uqid[0], (int) $uqid[1]);
1691 }
1692 $this->tpl->setOnScreenMessage('success', $lng->txt("msg_obj_modified"), true);
1693 }
1694 $ilCtrl->redirect($this, "listBlockedUsers");
1695 }
normalizeBlockedUserIds(string|array $user_q_ids)
static resetTries(int $a_q_id, int $a_user_id)
Reset tries for user and question.

References $lng, and ilPageQuestionProcessor\resetTries().

+ Here is the call graph for this function:

◆ saveAllTitles()

ilObjContentObjectGUI::saveAllTitles ( )

Save all titles of chapters/pages.

Definition at line 2403 of file class.ilObjContentObjectGUI.php.

2403 : void
2404 {
2405 $ilCtrl = $this->ctrl;
2406
2408 $this->lm,
2409 $this->edit_request->getTitles(),
2410 $this->requested_transl
2411 );
2412
2413 $this->tpl->setOnScreenMessage('success', $this->lng->txt("lm_save_titles"), true);
2414 $ilCtrl->redirect($this, "chapters");
2415 }
static saveTitles(ilObjLearningModule $a_lm, array $a_titles, string $a_lang="-")
Save titles for lm objects.

References ILIAS\Repository\lng(), and ilLMObject\saveTitles().

+ Here is the call graph for this function:

◆ saveExportId()

ilObjContentObjectGUI::saveExportId ( )

Definition at line 2604 of file class.ilObjContentObjectGUI.php.

2604 : void
2605 {
2606 $id = $this->edit_request->getExportIdPageId();
2607 $form = $this->getExportIdForm($id);
2608 if (!$form->isValid()) {
2609 $this->gui->clearAsnyOnloadCode();
2610 $this->gui->modal($this->lng->txt("cont_export_id"))
2611 ->form($form)
2612 ->send();
2613 return;
2614 }
2615
2616 $exp_id = ilUtil::stripSlashes((string) $form->getData("exportid"));
2617 if ($exp_id !== "" && !preg_match(
2618 "/^([a-zA-Z]+)[0-9a-zA-Z_]*$/",
2619 trim($exp_id)
2620 )) {
2621 $this->tpl->setOnScreenMessage(
2622 'failure',
2623 $this->lng->txt("cont_exp_ids_not_resp_format1") . ": a-z, A-Z, 0-9, '_'. " .
2624 $this->lng->txt("cont_exp_ids_not_resp_format3") . " " .
2625 $this->lng->txt("cont_exp_ids_not_resp_format2")
2626 );
2627 $this->gui->clearAsnyOnloadCode();
2628 $this->gui->modal($this->lng->txt("cont_export_id"))
2629 ->form($form)
2630 ->send();
2631 return;
2632 }
2633
2635 $this->lm->getId(),
2636 $id,
2637 $exp_id,
2639 );
2640
2641 $this->tpl->setOnScreenMessage('success', $this->lng->txt("cont_saved_export_ids"), true);
2642 $this->ctrl->redirect($this, "showExportIDsOverview");
2643 }
static saveExportId(int $a_lm_id, int $a_lmobj_id, string $a_exp_id, string $a_type="pg")

References $id, ilLMObject\_lookupType(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ilLMObject\saveExportId(), and ilUtil\stripSlashes().

+ Here is the call graph for this function:

◆ saveHelpMapping()

ilObjContentObjectGUI::saveHelpMapping ( )

Definition at line 2645 of file class.ilObjContentObjectGUI.php.

2645 : void
2646 {
2647 $id = $this->edit_request->getEditId();
2648 if ($id <= 0 || ilLMObject::_lookupContObjID($id) !== $this->lm->getId()) {
2649 $this->tpl->setOnScreenMessage("failure", $this->lng->txt("no_checkbox"), true);
2650 $this->ctrl->redirect($this, "showExportIDsOverview");
2651 return;
2652 }
2653
2654 $form = $this->getHelpMappingForm($id);
2655 if (!$form->isValid()) {
2656 $this->gui->clearAsnyOnloadCode();
2657 $this->gui->modal($this->lng->txt("cont_screen_ids"))
2658 ->form($form)
2659 ->send();
2660 return;
2661 }
2662
2663 $help_map = $this->help->internal()->domain()->map();
2664 $ids = explode("\n", (string) $form->getData("screen_ids"));
2665 $help_map->saveScreenIdsForChapter($id, $ids);
2666 $this->tpl->setOnScreenMessage('success', $this->lng->txt("msg_obj_modified"), true);
2667 $this->ctrl->redirect($this, "showExportIDsOverview");
2668 }

References $id, ilLMObject\_lookupContObjID(), ILIAS\Repository\ctrl(), ILIAS\Repository\help(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ saveMenuEntry()

ilObjContentObjectGUI::saveMenuEntry ( )

Definition at line 2157 of file class.ilObjContentObjectGUI.php.

2157 : void
2158 {
2159 $form = $this->initMenuEntryForm("create");
2160 if ($form->checkInput()) {
2161 $this->__initLMMenuEditor();
2162 $this->lmme_obj->setTitle($form->getInput("title"));
2163 $this->lmme_obj->setTarget($form->getInput("target"));
2164 $this->lmme_obj->setLinkRefId((int) $form->getInput("link_ref_id"));
2165
2166 if ($form->getInput("link_ref_id")) {
2167 $this->lmme_obj->setLinkType("intern");
2168 }
2169
2170 $this->lmme_obj->create();
2171
2172 $this->tpl->setOnScreenMessage('success', $this->lng->txt("msg_entry_added"), true);
2173 $this->ctrl->redirect($this, "editMenuProperties");
2174 } else {
2176 $this->addMenuEntry($form);
2177 }
2178 }
addMenuEntry(?ilPropertyFormGUI $form=null)
display add menu entry form
getInput(string $a_post_var, bool $ensureValidation=true)
Returns the input of an item, if item provides getInput method and as fallback the value of the HTTP-...

References ilPropertyFormGUI\checkInput(), ILIAS\Repository\ctrl(), ilPropertyFormGUI\getInput(), ILIAS\Repository\lng(), and ilPropertyFormGUI\setValuesByPost().

+ Here is the call graph for this function:

◆ saveMenuProperties()

ilObjContentObjectGUI::saveMenuProperties ( )

Definition at line 988 of file class.ilObjContentObjectGUI.php.

988 : void
989 {
990 $form = $this->initMenuForm();
991 if ($form->checkInput()) {
992 $this->lm->setActiveLMMenu((int) $form->getInput("cobj_act_lm_menu"));
993 //$this->lm->setActiveTOC((int) $form->getInput("cobj_act_toc"));
994 $this->lm->setActivePrintView((int) $form->getInput("cobj_act_print"));
995 $this->lm->setActivePreventGlossaryAppendix((int) $form->getInput("cobj_act_print_prev_glo"));
996 $this->lm->setHideHeaderFooterPrint((int) $form->getInput("hide_head_foot_print"));
997 $this->lm->updateProperties();
998 }
999
1000 $this->tpl->setOnScreenMessage('success', $this->lng->txt("msg_obj_modified"), true);
1001 $this->ctrl->redirect($this, "editMenuProperties");
1002 }

References $form, ilPropertyFormGUI\checkInput(), ILIAS\Repository\ctrl(), ilPropertyFormGUI\getInput(), initMenuForm(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ savePageLayout()

ilObjContentObjectGUI::savePageLayout ( )

Definition at line 2999 of file class.ilObjContentObjectGUI.php.

2999 : void
3000 {
3001 $lng = $this->lng;
3002 $ilCtrl = $this->ctrl;
3003
3004 $ilCtrl->setParameter($this, "hierarchy", $this->requested_hierarchy);
3005
3006 $ids = $this->edit_request->getIds();
3007 foreach ($ids as $id) {
3009 $id,
3010 $this->edit_request->getLayout(),
3011 $this->lm
3012 );
3013 }
3014 $this->tpl->setOnScreenMessage('success', $lng->txt("msg_obj_modified"), true);
3015
3016 if ($this->requested_hierarchy) {
3017 $ilCtrl->redirect($this, "chapters");
3018 } else {
3019 $ilCtrl->redirect($this, "pages");
3020 }
3021 }
static writeLayout(int $a_obj_id, string $a_layout, ?ilObjLearningModule $a_lm=null)
Write layout setting.

References $id, $lng, and ilLMObject\writeLayout().

+ Here is the call graph for this function:

◆ saveProperties()

ilObjContentObjectGUI::saveProperties ( )

save properties

Definition at line 828 of file class.ilObjContentObjectGUI.php.

828 : void
829 {
831 $ilUser = $this->user;
833 $obj_service = $this->object_service;
834
835 $add_info = "";
836
837 $valid = false;
838 $this->initPropertiesForm();
840 if ($form->checkInput()) {
841 $ot = $this->lm->getObjectProperties()->getPropertyTranslations();
842 if ($ot->getContentTranslationActivated()) {
843 $this->lm->getObjectProperties()->storePropertyTranslations(
844 $ot->withDefaultTitle($form->getInput('title'))
845 ->withDefaultDescription($form->getInput('description'))
846 );
847 }
848
849 $this->lm->setTitle($form->getInput('title'));
850 $this->lm->setDescription($form->getInput('description'));
851 $this->lm->setPageHeader($form->getInput("lm_pg_header"));
852 $this->lm->setTOCMode($form->getInput("toc_mode"));
853 $this->lm->setOfflineStatus(!($form->getInput('cobj_online')));
854 $this->lm->setActiveNumbering((bool) $form->getInput("cobj_act_number"));
855 $this->lm->setCleanFrames((bool) $form->getInput("cobj_clean_frames"));
856 if (!$ilSetting->get('disable_comments')) {
857 $this->lm->setPublicNotes($form->getInput("cobj_pub_notes"));
858 }
859 $this->lm->setRating((bool) $form->getInput("rating"));
860 $this->lm->setRatingPages((bool) $form->getInput("rating_pages"));
861 $this->lm->setDisableDefaultFeedback((int) $form->getInput("disable_def_feedback"));
862 $this->lm->setProgressIcons((int) $form->getInput("progr_icons"));
863 $this->reading_time_gui->saveSettingFromForm($this->form);
864
865 $add_info = "";
866 $store_tries = $form->getInput("store_tries");
867 if ($form->getInput("restrict_forw_nav") && !$form->getInput("store_tries")) {
868 $store_tries = 1;
869 $add_info = "</br>" . $lng->txt("cont_automatically_set_store_tries");
870 $add_info = str_replace("$1", $lng->txt("cont_tries_store"), $add_info);
871 $add_info = str_replace("$2", $lng->txt("cont_restrict_forw_nav"), $add_info);
872 }
873
874 $this->lm->setStoreTries((int) $store_tries);
875 $this->lm->setRestrictForwardNavigation((int) $form->getInput("restrict_forw_nav"));
876 $this->lm->updateProperties();
877 $this->lm->update();
878
879 // tile image
880 $obj_service->commonSettings()->legacyForm($this->form, $this->lm)->saveTileImage();
881
884 $ilUser->getId(),
885 $this->lm->getId(),
886 (bool) $this->form->getInput("notification_blocked_users")
887 );
888
889 // services
891 $this->object->getId(),
892 $this->form,
893 array(
895 )
896 );
897
898
899 // Update ecs export settings
900 $ecs = new ilECSLearningModuleSettings($this->lm);
901 if ($ecs->handleSettingsUpdate($form)) {
902 $valid = true;
903 }
904 }
905
906 if ($valid) {
907 $this->tpl->setOnScreenMessage('success', $this->lng->txt("msg_obj_modified") . $add_info, true);
908 $this->ctrl->redirect($this, "properties");
909 } else {
910 $lng->loadLanguageModule("style");
911 $this->setTabs("settings");
912 $this->setSubTabs("cont_general_properties");
913
914 $this->form->setValuesByPost();
915 $this->tpl->setContent($this->form->getHTML());
916 }
917 }
static setNotification(int $type, int $user_id, int $id, bool $status=true)
Set notification status for object and user.
static updateServiceSettingsForm(int $obj_id, ilPropertyFormGUI $form, array $services)

References $form, $ilSetting, ilObjectGUI\$lng, ilObjectGUI\$object_service, ilObjectGUI\$settings, ilObjectGUI\$user, ilPropertyFormGUI\checkInput(), ILIAS\Repository\ctrl(), ILIAS\Repository\form(), ilPropertyFormGUI\getInput(), ilObjectServiceSettingsGUI\INFO_TAB_VISIBILITY, initPropertiesForm(), ILIAS\Repository\lng(), ilLanguage\loadLanguageModule(), ILIAS\Repository\object(), ilNotification\setNotification(), setSubTabs(), ilObjectGUI\setTabs(), ilPropertyFormGUI\setTitle(), ilLanguage\txt(), ilNotification\TYPE_LM_BLOCKED_USERS, and ilObjectServiceSettingsGUI\updateServiceSettingsForm().

+ Here is the call graph for this function:

◆ saveTooltip()

ilObjContentObjectGUI::saveTooltip ( )

Definition at line 2799 of file class.ilObjContentObjectGUI.php.

2799 : void
2800 {
2801 $id = $this->edit_request->getEditId();
2802 if ($this->getTooltip($id) === null) {
2803 $this->tpl->setOnScreenMessage("failure", $this->lng->txt("no_checkbox"), true);
2804 $this->ctrl->redirect($this, "showTooltipList");
2805 return;
2806 }
2807
2808 $form = $this->getTooltipForm($id);
2809 if (!$form->isValid()) {
2810 $this->gui->clearAsnyOnloadCode();
2811 $this->gui->modal($this->lng->txt("edit"))
2812 ->form($form)
2813 ->send();
2814 return;
2815 }
2816
2817 $this->help->internal()->domain()->tooltips()->updateTooltip(
2818 $id,
2819 (string) $form->getData("text"),
2820 (string) $form->getData("tt_id")
2821 );
2822 $this->tpl->setOnScreenMessage("success", $this->lng->txt("msg_obj_modified"), true);
2823 $this->ctrl->redirect($this, "showTooltipList");
2824 }

References $id, ILIAS\Repository\ctrl(), ILIAS\Repository\help(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ selectFooter()

ilObjContentObjectGUI::selectFooter ( int  $id = 0)

select page as footer

Definition at line 2380 of file class.ilObjContentObjectGUI.php.

2380 : void
2381 {
2382 $ids = $id > 0 ? [$id] : $this->edit_request->getIds();
2383 if (count($ids) == 0) {
2384 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_checkbox"), true);
2385 $this->ctrl->redirect($this, "pages");
2386 }
2387 if (count($ids) > 1) {
2388 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("cont_select_max_one_item"), true);
2389 $this->ctrl->redirect($this, "pages");
2390 }
2391 if ($ids[0] != $this->lm->getFooterPage()) {
2392 $this->lm->setFooterPage($ids[0]);
2393 } else {
2394 $this->lm->setFooterPage(0);
2395 }
2396 $this->lm->updateProperties();
2397 $this->ctrl->redirect($this, "pages");
2398 }

References $id, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ selectHeader()

ilObjContentObjectGUI::selectHeader ( int  $id = 0)

select page as header

Definition at line 2357 of file class.ilObjContentObjectGUI.php.

2357 : void
2358 {
2359 $ids = $id > 0 ? [$id] : $this->edit_request->getIds();
2360 if (count($ids) == 0) {
2361 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_checkbox"), true);
2362 $this->ctrl->redirect($this, "pages");
2363 }
2364 if (count($ids) > 1) {
2365 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("cont_select_max_one_item"), true);
2366 $this->ctrl->redirect($this, "pages");
2367 }
2368 if ($ids[0] != $this->lm->getHeaderPage()) {
2369 $this->lm->setHeaderPage($ids[0]);
2370 } else {
2371 $this->lm->setHeaderPage(0);
2372 }
2373 $this->lm->updateProperties();
2374 $this->ctrl->redirect($this, "pages");
2375 }

References $id, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ selectLMGlossary()

ilObjContentObjectGUI::selectLMGlossary ( )

Definition at line 3112 of file class.ilObjContentObjectGUI.php.

3112 : void
3113 {
3114 $ilCtrl = $this->ctrl;
3115 $lng = $this->lng;
3116
3117 $glos = $this->lm->getAutoGlossaries();
3118 $glo_ref_id = $this->requested_glo_ref_id;
3119 $glo_id = ilObject::_lookupObjId($glo_ref_id);
3120 if (!in_array($glo_id, $glos)) {
3121 $glos[] = $glo_id;
3122 }
3123 $this->lm->setAutoGlossaries($glos);
3124 $this->lm->update();
3125
3126 $this->tpl->setOnScreenMessage('success', $lng->txt("msg_obj_modified"), true);
3127 $ilCtrl->redirect($this, "editGlossaries");
3128 }

References $lng, and ilObject\_lookupObjId().

+ Here is the call graph for this function:

◆ selectLMGlossaryLink()

ilObjContentObjectGUI::selectLMGlossaryLink ( )

Definition at line 3105 of file class.ilObjContentObjectGUI.php.

3105 : void
3106 {
3107 $glo_ref_id = $this->requested_glo_ref_id;
3108 $this->lm->autoLinkGlossaryTerms($glo_ref_id);
3109 $this->selectLMGlossary();
3110 }

◆ sendMailToBlockedUsers()

ilObjContentObjectGUI::sendMailToBlockedUsers ( string|array  $user_q_ids = [])

Definition at line 1713 of file class.ilObjContentObjectGUI.php.

1713 : void
1714 {
1715 $ilCtrl = $this->ctrl;
1716
1717 $user_q_ids = $this->normalizeBlockedUserIds($user_q_ids);
1718 if (count($user_q_ids) == 0) {
1719 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_checkbox"), 1);
1720 $ilCtrl->redirect($this, "listBlockedUsers");
1721 }
1722
1723 $rcps = array();
1724 foreach ($user_q_ids as $uqid) {
1725 $uqid = explode(":", $uqid);
1726 $login = ilObjUser::_lookupLogin($uqid[1]);
1727 if (!in_array($login, $rcps)) {
1728 $rcps[] = $login;
1729 }
1730 }
1732 $this,
1733 'listBlockedUsers',
1734 array(),
1735 array(
1736 'type' => 'new',
1737 'rcp_to' => implode(',', $rcps),
1738 'sig' => $this->getBlockedUsersMailSignature()
1739 )
1740 ));
1741 }
static getRedirectTarget( $gui, string $cmd, array $gui_params=[], array $mail_params=[], array $context_params=[])
static _lookupLogin(int $a_user_id)
static redirect(string $a_script)

References ilObjUser\_lookupLogin(), ilMailFormCall\getRedirectTarget(), ILIAS\Repository\lng(), and ilUtil\redirect().

+ Here is the call graph for this function:

◆ setContentSubTabs()

ilObjContentObjectGUI::setContentSubTabs ( string  $a_active)

Definition at line 1773 of file class.ilObjContentObjectGUI.php.

1773 : void
1774 {
1775 $ilTabs = $this->tabs;
1776 $lng = $this->lng;
1777 $ilCtrl = $this->ctrl;
1778
1779 $lm_set = new ilSetting("lm");
1780
1781 // chapters
1782 $this->ctrl->setParameterByClass(static::class, "sub_type", "st");
1783 $ilTabs->addSubTab(
1784 "sub_chapters",
1785 $lng->txt("objs_st"),
1786 $this->ctrl->getLinkTargetByClass(EditSubObjectsGUI::class)
1787 );
1788
1789
1790 // all pages
1791 $ilTabs->addSubTab(
1792 "pages",
1793 $lng->txt("cont_all_pages"),
1794 $ilCtrl->getLinkTarget($this, "pages")
1795 );
1796
1797 // all pages
1798 $ilTabs->addSubTab(
1799 "short_titles",
1800 $lng->txt("cont_short_titles"),
1801 $ilCtrl->getLinkTargetByClass("illmeditshorttitlesgui", "")
1802 );
1803
1804 // export ids
1805 if ($lm_set->get("html_export_ids")) {
1806 if (!ilObjContentObject::isOnlineHelpModule($this->lm->getRefId())) {
1807 $ilTabs->addSubTab(
1808 "export_ids",
1809 $lng->txt("cont_html_export_ids"),
1810 $ilCtrl->getLinkTarget($this, "showExportIDsOverview")
1811 );
1812 }
1813 }
1814 if (ilObjContentObject::isOnlineHelpModule($this->lm->getRefId())) {
1815 $lng->loadLanguageModule("help");
1816 $ilTabs->addSubTab(
1817 "export_ids",
1818 $lng->txt("cont_online_help_ids"),
1819 $ilCtrl->getLinkTarget($this, "showExportIDsOverview")
1820 );
1821
1822 $ilTabs->addSubTab(
1823 "help_tooltips",
1824 $lng->txt("help_tooltips"),
1825 $ilCtrl->getLinkTarget($this, "showTooltipList")
1826 );
1827 }
1828
1829 // list links
1830 $ilTabs->addSubTab(
1831 "internal_links",
1832 $lng->txt("cont_internal_links"),
1833 $ilCtrl->getLinkTarget($this, "listLinks")
1834 );
1835
1836 // maintenance
1837 $ilTabs->addSubTab(
1838 "maintenance",
1839 $lng->txt("cont_maintenance"),
1840 $ilCtrl->getLinkTarget($this, "showMaintenance")
1841 );
1842
1843 // srt files
1844 $ilTabs->addSubTab(
1845 "import",
1846 $lng->txt("cont_import"),
1847 $ilCtrl->getLinkTargetByClass("illmimportgui", "")
1848 );
1849
1850 $ilTabs->activateSubTab($a_active);
1851 $ilTabs->activateTab("content");
1852 }
static isOnlineHelpModule(int $a_id, bool $a_as_obj_id=false)
Is module an online module.
ILIAS Setting Class.
$lm_set

References $lm_set, $lng, ILIAS\Repository\ctrl(), and ilObjContentObject\isOnlineHelpModule().

+ Here is the call graph for this function:

◆ setMediaSubTabs()

ilObjContentObjectGUI::setMediaSubTabs ( string  $a_active)

Definition at line 1854 of file class.ilObjContentObjectGUI.php.

1854 : void
1855 {
1856 $ilTabs = $this->tabs;
1857 $lng = $this->lng;
1858 $ilCtrl = $this->ctrl;
1859
1860 // media
1861 $ilTabs->addSubTab(
1862 "usages",
1863 $lng->txt("cont_mob_usages"),
1864 $this->ctrl->getLinkTargetByClass(ilMediaObjectOverviewGUI::class, "show")
1865 );
1866
1867 // srt files
1868 $ilTabs->addSubTab(
1869 "srt_files",
1870 $lng->txt("cont_subtitle_files"),
1871 $ilCtrl->getLinkTargetByClass("ilmobmultisrtuploadgui", "")
1872 );
1873
1874 $ilTabs->activateSubTab($a_active);
1875 }

References $lng.

◆ setPageLayout()

ilObjContentObjectGUI::setPageLayout ( int|bool  $a_in_hierarchy = false)

Set layout for multiple pages.

Definition at line 2942 of file class.ilObjContentObjectGUI.php.

2944 : void {
2945 $tpl = $this->tpl;
2946 $ilCtrl = $this->ctrl;
2947 $lng = $this->lng;
2948
2949 $is_in_hierarchy = is_bool($a_in_hierarchy)
2950 ? $a_in_hierarchy
2951 : false;
2952 $ids = is_int($a_in_hierarchy) && $a_in_hierarchy > 0
2953 ? [$a_in_hierarchy]
2954 : $this->edit_request->getIds();
2955 if (count($ids) == 0) {
2956 $this->tpl->setOnScreenMessage('failure', $lng->txt("no_checkbox"), true);
2957
2958 if ($is_in_hierarchy) {
2959 $ilCtrl->redirect($this, "chapters");
2960 } else {
2961 $ilCtrl->redirect($this, "pages");
2962 }
2963 }
2964
2965 $this->initSetPageLayoutForm($ids);
2966
2967 $tpl->setContent($this->form->getHTML());
2968 }

References $lng.

◆ setPageLayoutInHierarchy()

ilObjContentObjectGUI::setPageLayoutInHierarchy ( )

Set layout for multiple pages.

Definition at line 2931 of file class.ilObjContentObjectGUI.php.

2931 : void
2932 {
2933 $ilCtrl = $this->ctrl;
2934 $ilCtrl->setParameter($this, "hierarchy", "1");
2935 $this->setPageLayout(true);
2936 }
setPageLayout(int|bool $a_in_hierarchy=false)
Set layout for multiple pages.

◆ setQuestionsSubTabs()

ilObjContentObjectGUI::setQuestionsSubTabs ( string  $a_active)

Definition at line 1877 of file class.ilObjContentObjectGUI.php.

1877 : void
1878 {
1879 $ilTabs = $this->tabs;
1880 $lng = $this->lng;
1881 $ilCtrl = $this->ctrl;
1882
1883 // usage
1884 $ilTabs->addSubTab(
1885 "question_usage",
1886 $lng->txt("cont_question_usage"),
1887 $ilCtrl->getLinkTarget($this, "listQuestionUsages")
1888 );
1889
1890 // chapters
1891 $ilTabs->addSubTab(
1892 "question_stats",
1893 $lng->txt("cont_question_stats"),
1894 $ilCtrl->getLinkTarget($this, "listQuestions")
1895 );
1896
1897 // blocked users
1898 $ilTabs->addSubTab(
1899 "blocked_users",
1900 $lng->txt("cont_blocked_users"),
1901 $ilCtrl->getLinkTarget($this, "listBlockedUsers")
1902 );
1903
1904 $ilTabs->activateSubTab($a_active);
1905 }

References $lng.

◆ setSubTabs()

ilObjContentObjectGUI::setSubTabs ( string  $a_active)

Definition at line 2005 of file class.ilObjContentObjectGUI.php.

2005 : void
2006 {
2007 $ilTabs = $this->tabs;
2009
2010 if (in_array(
2011 $a_active,
2012 array("settings", "cont_style", "cont_lm_menu", "public_section",
2013 "cont_glossaries", "cont_multilinguality", "obj_multilinguality",
2014 "lti_provider")
2015 )) {
2016 // general properties
2017 $ilTabs->addSubTabTarget(
2018 "settings",
2019 $this->ctrl->getLinkTarget($this, 'properties'),
2020 "",
2021 ""
2022 );
2023
2024 // style properties
2025 $ilTabs->addSubTabTarget(
2026 "cont_style",
2027 $this->ctrl->getLinkTargetByClass("ilObjectContentStyleSettingsGUI", ""),
2028 "",
2029 "ilObjectContentStyleSettingsGUI"
2030 );
2031
2032 // menu properties
2033 $ilTabs->addSubTabTarget(
2034 "cont_lm_menu",
2035 $this->ctrl->getLinkTarget($this, 'editMenuProperties'),
2036 "",
2037 ""
2038 );
2039
2040 // glossaries
2041 $ilTabs->addSubTabTarget(
2042 "cont_glossaries",
2043 $this->ctrl->getLinkTarget($this, 'editGlossaries'),
2044 "",
2045 ""
2046 );
2047
2048 $ilTabs->addSubTabTarget(
2049 "obj_multilinguality",
2050 $this->ctrl->getLinkTargetByClass(TranslationGUI::class, "")
2051 );
2052
2053 $lti_settings = new ilLTIProviderObjectSettingGUI($this->lm->getRefId());
2054 if ($lti_settings->hasSettingsAccess()) {
2055 $ilTabs->addSubTabTarget(
2056 'lti_provider',
2057 $this->ctrl->getLinkTargetByClass(ilLTIProviderObjectSettingGUI::class)
2058 );
2059 }
2060
2061 $ilTabs->setSubTabActive($a_active);
2062 }
2063 }
The tab of an ILIAS object that releases it to the platforms allowed for its type,...

References $ilSetting, $settings, and ILIAS\Repository\ctrl().

Referenced by editMenuProperties(), properties(), and saveProperties().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setTabs()

ilObjContentObjectGUI::setTabs ( string  $a_act = "")
protected

Definition at line 1765 of file class.ilObjContentObjectGUI.php.

1765 : void
1766 {
1767 parent::setTitleAndDescription();
1768 $ilHelp = $this->help;
1769 $ilHelp->setScreenIdComponent("lm");
1770 $this->addTabs($a_act);
1771 }
setScreenIdComponent(string $a_comp)

◆ showActions()

ilObjContentObjectGUI::showActions ( array  $a_actions)

Definition at line 1406 of file class.ilObjContentObjectGUI.php.

1406 : void
1407 {
1408 $d = null;
1409 foreach ($a_actions as $name => $lng) {
1410 $d[$name] = array("name" => $name, "lng" => $lng);
1411 }
1412
1413 $notoperations = array();
1414
1415 $operations = array();
1416
1417 if (is_array($d)) {
1418 foreach ($d as $row) {
1419 if (!in_array($row["name"], $notoperations)) {
1420 $operations[] = $row;
1421 }
1422 }
1423 }
1424
1425 if (count($operations) > 0) {
1426 foreach ($operations as $val) {
1427 $this->tpl->setCurrentBlock("operation_btn");
1428 $this->tpl->setVariable("BTN_NAME", $val["name"]);
1429 $this->tpl->setVariable("BTN_VALUE", $this->lng->txt($val["lng"]));
1430 $this->tpl->parseCurrentBlock();
1431 }
1432
1433 $this->tpl->setCurrentBlock("operation");
1434 $this->tpl->setVariable("IMG_ARROW", ilUtil::getImagePath("nav/arrow_downright.svg"));
1435 $this->tpl->parseCurrentBlock();
1436 }
1437 }

References Vendor\Package\$d, $lng, ilUtil\getImagePath(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ showEntrySelector()

ilObjContentObjectGUI::showEntrySelector ( )

Definition at line 2326 of file class.ilObjContentObjectGUI.php.

2326 : void
2327 {
2328 $ilTabs = $this->tabs;
2329 $ilCtrl = $this->ctrl;
2330
2331 $this->setTabs();
2332
2333 $ilTabs->setTabActive("settings");
2334 $this->setSubTabs("cont_lm_menu");
2335
2336 $ilCtrl->saveParameter($this, array("menu_entry"));
2337
2338 $this->tpl->setOnScreenMessage('info', $this->lng->txt("lm_menu_select_object_to_add"));
2339
2341 $this,
2342 "showEntrySelector",
2343 $this,
2344 "addMenuEntry",
2345 "link_ref_id"
2346 );
2347 //$exp->setTypeWhiteList(array("root", "cat", "grp", "crs", "glo", "fold"));
2348 $exp->setClickableTypes(array('mcst', 'mep', 'cat', 'lm','glo','frm','exc','tst','svy', 'chat', 'wiki', 'sahs', "crs", "grp", "book", "tst", "file"));
2349 if (!$exp->handleCommand()) {
2350 $this->tpl->setContent($exp->getHTML());
2351 }
2352 }
Explorer for selecting repository items.

References ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ showExportIDsOverview()

ilObjContentObjectGUI::showExportIDsOverview ( bool  $a_validation = false)

Definition at line 2515 of file class.ilObjContentObjectGUI.php.

2515 : void
2516 {
2517 $tpl = $this->tpl;
2518 $ilToolbar = $this->toolbar;
2519 $lng = $this->lng;
2520 $ilCtrl = $this->ctrl;
2521
2522 $this->setTabs();
2523 $this->setContentSubTabs("export_ids");
2524
2525 if (ilObjContentObject::isOnlineHelpModule($this->lm->getRefId())) {
2526 // toolbar
2527 $ilToolbar->setFormAction($ilCtrl->getFormAction($this));
2528 $lm_tree = $this->lm->getTree();
2529 $childs = $lm_tree->getChilds($lm_tree->readRootId());
2530 $options = array("" => $lng->txt("all"));
2531 foreach ($childs as $c) {
2532 $options[$c["child"]] = $c["title"];
2533 }
2534 $si = new ilSelectInputGUI($this->lng->txt("help_component"), "help_chap");
2535 $si->setOptions($options);
2536 $si->setValue(ilSession::get("help_chap"));
2537 $ilToolbar->addInputItem($si, true);
2538 $ilToolbar->addFormButton($lng->txt("help_filter"), "filterHelpChapters");
2539
2540 $tbl = $this->getHelpMappingTable();
2541 if ($tbl->handleCommand()) {
2542 return;
2543 }
2544 $tpl->setContent($tbl->render());
2545 return;
2546 } else {
2547 $tbl = $this->gui->editing()->exportIdsTableBuilder(
2548 $this->lm->getId(),
2549 $this,
2550 "showExportIDsOverview"
2551 )->getTable();
2552 if ($tbl->handleCommand()) {
2553 return;
2554 }
2555 $tpl->setContent($tbl->render());
2556 return;
2557 }
2558
2559 }
getChilds(int $a_node_id, string $a_order="", string $a_direction="ASC")
get child nodes of given node

References Vendor\Package\$c, $lng, ILIAS\UI\Implementation\Component\Input\Field\$options, ILIAS\News\Common\Table\$tpl, ilSession\get(), ilTree\getChilds(), ilObjContentObject\isOnlineHelpModule(), ILIAS\Repository\lng(), ilTree\readRootId(), and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ showExportOptionsHTML()

ilObjContentObjectGUI::showExportOptionsHTML ( )
protected

Definition at line 568 of file class.ilObjContentObjectGUI.php.

568 : void
569 {
570 $ot = $this->lm->getObjectProperties()->getPropertyTranslations();
571 if ($ot->getContentTranslationActivated()) {
572 $this->addHeaderAction();
573 $this->addLocations(true);
574 $this->setTabs("export");
575 $this->ui->mainTemplate()->setContent($this->ui->renderer()->render($this->buildExportOptionsFormHTML()));
576 }
577 if (!$ot->getContentTranslationActivated()) {
578 $this->doExportHTML();
579 }
580 }

References ilObjectGUI\addHeaderAction(), addLocations(), doExportHTML(), ilObjectGUI\setTabs(), and ILIAS\Repository\ui().

+ Here is the call graph for this function:

◆ showExportOptionsXML()

ilObjContentObjectGUI::showExportOptionsXML ( )
protected

Definition at line 560 of file class.ilObjContentObjectGUI.php.

560 : void
561 {
562 $this->addHeaderAction();
563 $this->addLocations(true);
564 $this->setTabs("export");
565 $this->ui->mainTemplate()->setContent($this->ui->renderer()->render($this->buildExportOptionsFormXML()));
566 }

References ilObjectGUI\addHeaderAction(), addLocations(), ilObjectGUI\setTabs(), and ILIAS\Repository\ui().

+ Here is the call graph for this function:

◆ showLMGlossarySelector()

ilObjContentObjectGUI::showLMGlossarySelector ( )

Definition at line 3065 of file class.ilObjContentObjectGUI.php.

3065 : void
3066 {
3067 $tpl = $this->tpl;
3068 $ilCtrl = $this->ctrl;
3070 $ilTabs = $this->tabs;
3071
3072 $this->setTabs();
3073 $ilTabs->setTabActive("settings");
3074 $this->setSubTabs("cont_glossaries");
3075
3076 $exp = new ilSearchRootSelector($ilCtrl->getLinkTarget($this, 'showLMGlossarySelector'));
3077 $exp->setExpand($this->requested_search_root_expand ?: $tree->readRootId());
3078 $exp->setPathOpen($this->object->getRefId());
3079 $exp->setExpandTarget($ilCtrl->getLinkTarget($this, 'showLMGlossarySelector'));
3080 $exp->setTargetClass(get_class($this));
3081 $exp->setCmd('confirmGlossarySelection');
3082 $exp->setClickableTypes(array("glo"));
3083 $exp->addFilter("glo");
3084
3085 // build html-output
3086 $exp->setOutput(0);
3087 $tpl->setContent($exp->getOutput());
3088 }

References ILIAS\News\Common\Table\$tpl, ILIAS\Repository\object(), and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ showMaintenance()

ilObjContentObjectGUI::showMaintenance ( )

Show maintenance.

Definition at line 1286 of file class.ilObjContentObjectGUI.php.

1286 : void
1287 {
1288 $ilToolbar = $this->toolbar;
1289
1290 $this->setTabs();
1291 $this->setContentSubTabs("maintenance");
1292
1293 $ilToolbar->addButton(
1294 $this->lng->txt("cont_fix_tree"),
1295 $this->ctrl->getLinkTarget($this, "fixTreeConfirm")
1296 );
1297 }

References ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ showTooltipList()

ilObjContentObjectGUI::showTooltipList ( )

Definition at line 2702 of file class.ilObjContentObjectGUI.php.

2702 : void
2703 {
2704 $tpl = $this->tpl;
2705 $ilToolbar = $this->toolbar;
2706 $ilCtrl = $this->ctrl;
2707 $lng = $this->lng;
2708
2709 $this->setTabs();
2710 $this->setContentSubTabs("help_tooltips");
2711
2712 $ilToolbar->setFormAction($ilCtrl->getFormAction($this));
2713 $ti = new ilTextInputGUI($this->lng->txt("help_tooltip_id"), "tooltip_id");
2714 $ti->setMaxLength(200);
2715 $ti->setSize(20);
2716 $ilToolbar->addInputItem($ti, true);
2717 $ilToolbar->addFormButton($lng->txt("add"), "addTooltip");
2718 $ilToolbar->addSeparator();
2719
2720 $options = $this->help->internal()->domain()->tooltips()->getTooltipComponents();
2721 if (ilSession::get("help_tt_comp") != "") {
2722 $options[ilSession::get("help_tt_comp")] = ilSession::get("help_tt_comp");
2723 }
2724 $si = new ilSelectInputGUI($this->lng->txt("help_component"), "help_tt_comp");
2725 $si->setOptions($options);
2726 $si->setValue(ilSession::get("help_tt_comp"));
2727 $ilToolbar->addInputItem($si, true);
2728 $ilToolbar->addFormButton($lng->txt("help_filter"), "filterTooltips");
2729
2730 $tbl = $this->gui->helpTooltipTableBuilder(
2731 (string) ilSession::get("help_tt_comp"),
2732 $this,
2733 "showTooltipList"
2734 )->getTable();
2735
2736 if ($tbl->handleCommand()) {
2737 return;
2738 }
2739
2740 $tpl->setContent($tbl->render());
2741 }

References $lng, ILIAS\UI\Implementation\Component\Input\Field\$options, ILIAS\News\Common\Table\$tpl, ilSession\get(), ILIAS\Repository\help(), ILIAS\Repository\lng(), and ILIAS\UICore\GlobalTemplate\setContent().

+ Here is the call graph for this function:

◆ switchToLanguage()

ilObjContentObjectGUI::switchToLanguage ( )

Definition at line 3165 of file class.ilObjContentObjectGUI.php.

3165 : void
3166 {
3167 $ilCtrl = $this->ctrl;
3168
3169 $ilCtrl->setParameter($this, "transl", $this->requested_totransl);
3170 if ($this->lang_switch_mode == "short_titles") {
3171 $ilCtrl->redirectByClass("illmeditshorttitlesgui", "");
3172 }
3173 $ilCtrl->redirect($this, "chapters");
3174 }

◆ unlockQuestion()

ilObjContentObjectGUI::unlockQuestion ( string|array  $user_q_ids = [])

Definition at line 1697 of file class.ilObjContentObjectGUI.php.

1697 : void
1698 {
1699 $lng = $this->lng;
1700 $ilCtrl = $this->ctrl;
1701
1702 $user_q_ids = $this->normalizeBlockedUserIds($user_q_ids);
1703 if (count($user_q_ids) > 0) {
1704 foreach ($user_q_ids as $uqid) {
1705 $uqid = explode(":", $uqid);
1706 ilPageQuestionProcessor::unlock((int) $uqid[0], (int) $uqid[1]);
1707 }
1708 $this->tpl->setOnScreenMessage('success', $lng->txt("msg_obj_modified"), true);
1709 }
1710 $ilCtrl->redirect($this, "listBlockedUsers");
1711 }
static unlock(int $a_q_id, int $a_user_id)
Unlock question for user.

References $lng, and ilPageQuestionProcessor\unlock().

+ Here is the call graph for this function:

◆ updateMenuEntry()

ilObjContentObjectGUI::updateMenuEntry ( )

Definition at line 2297 of file class.ilObjContentObjectGUI.php.

2297 : void
2298 {
2299 $form = $this->initMenuEntryForm("edit");
2300 if ($form->checkInput()) {
2301 if (empty($this->requested_menu_entry)) {
2302 $this->tpl->setOnScreenMessage('failure', $this->lng->txt("no_menu_entry_id"), true);
2303 $this->ctrl->redirect($this, "editMenuProperties");
2304 return;
2305 }
2306
2307 $this->__initLMMenuEditor();
2308 $this->lmme_obj->readEntry($this->requested_menu_entry);
2309 $this->lmme_obj->setTitle($form->getInput("title"));
2310 $this->lmme_obj->setTarget($form->getInput("target"));
2311 if ($form->getInput("link_ref_id")) {
2312 $this->lmme_obj->setLinkType("intern");
2313 }
2314 if (is_int(strpos($form->getInput("target"), "."))) {
2315 $this->lmme_obj->setLinkType("extern");
2316 }
2317 $this->lmme_obj->update();
2318 $this->tpl->setOnScreenMessage('success', $this->lng->txt("msg_entry_updated"), true);
2319 $this->ctrl->redirect($this, "editMenuProperties");
2320 } else {
2322 $this->editMenuEntry($form);
2323 }
2324 }

References ilPropertyFormGUI\checkInput(), ILIAS\Repository\ctrl(), ilPropertyFormGUI\getInput(), ILIAS\Repository\lng(), and ilPropertyFormGUI\setValuesByPost().

+ Here is the call graph for this function:

◆ view()

ilObjContentObjectGUI::view ( )

Reimplemented in ilObjLearningModuleGUI.

Definition at line 1439 of file class.ilObjContentObjectGUI.php.

1439 : void
1440 {
1441 if (strtolower($this->requested_baseClass) == "iladministrationgui") {
1442 $this->prepareOutput();
1443 parent::viewObject();
1444 } else {
1445 $this->viewObject();
1446 }
1447 }
viewObject()
viewObject container presentation for "administration -> repository, trash, permissions"
prepareOutput(bool $show_sub_objects=true)

Field Documentation

◆ $component_repository

ilComponentRepository ilObjContentObjectGUI::$component_repository
protected

Definition at line 57 of file class.ilObjContentObjectGUI.php.

◆ $content_style_service

ILIAS Style Content Service ilObjContentObjectGUI::$content_style_service
protected

Definition at line 81 of file class.ilObjContentObjectGUI.php.

◆ $db

ilDBInterface ilObjContentObjectGUI::$db
protected

Definition at line 54 of file class.ilObjContentObjectGUI.php.

◆ $domain

ILIAS LearningModule InternalDomainService ilObjContentObjectGUI::$domain
protected

Definition at line 44 of file class.ilObjContentObjectGUI.php.

◆ $edit_request

EditingGUIRequest ilObjContentObjectGUI::$edit_request
protected

Definition at line 80 of file class.ilObjContentObjectGUI.php.

Referenced by __construct(), and proceedDragDrop().

◆ $form

ilPropertyFormGUI ilObjContentObjectGUI::$form
protected

◆ $gui

ILIAS LearningModule InternalGUIService ilObjContentObjectGUI::$gui
protected

Definition at line 43 of file class.ilObjContentObjectGUI.php.

◆ $help

ilHelpGUI ilObjContentObjectGUI::$help
protected

Definition at line 53 of file class.ilObjContentObjectGUI.php.

◆ $lang_switch_mode

string ilObjContentObjectGUI::$lang_switch_mode
protected

Definition at line 50 of file class.ilObjContentObjectGUI.php.

◆ $lm

ilObjLearningModule ilObjContentObjectGUI::$lm
protected

Definition at line 79 of file class.ilObjContentObjectGUI.php.

◆ $lm_obj

ilObjLearningModule ilObjContentObjectGUI::$lm_obj
protected

Definition at line 49 of file class.ilObjContentObjectGUI.php.

◆ $lm_tree

ilLMTree ilObjContentObjectGUI::$lm_tree
protected

Definition at line 83 of file class.ilObjContentObjectGUI.php.

◆ $lmme_obj

ilLMMenuEditor ilObjContentObjectGUI::$lmme_obj
protected

Definition at line 48 of file class.ilObjContentObjectGUI.php.

◆ $log

ilLogger ilObjContentObjectGUI::$log
protected

Definition at line 55 of file class.ilObjContentObjectGUI.php.

◆ $page_manager

ILIAS COPage Page PageManagerInterface ilObjContentObjectGUI::$page_manager
protected

Definition at line 45 of file class.ilObjContentObjectGUI.php.

◆ $rbacsystem

ilRbacSystem ilObjContentObjectGUI::$rbacsystem
protected

Definition at line 46 of file class.ilObjContentObjectGUI.php.

◆ $reading_time_gui

ILIAS LearningModule ReadingTime SettingsGUI ilObjContentObjectGUI::$reading_time_gui
protected

Definition at line 47 of file class.ilObjContentObjectGUI.php.

◆ $requested_active_node

int ilObjContentObjectGUI::$requested_active_node = 0
protected

Definition at line 74 of file class.ilObjContentObjectGUI.php.

◆ $requested_backcmd

string ilObjContentObjectGUI::$requested_backcmd = ""
protected

Definition at line 65 of file class.ilObjContentObjectGUI.php.

◆ $requested_baseClass

string ilObjContentObjectGUI::$requested_baseClass = ""
protected

Definition at line 62 of file class.ilObjContentObjectGUI.php.

◆ $requested_glo_id

int ilObjContentObjectGUI::$requested_glo_id = 0
protected

Definition at line 71 of file class.ilObjContentObjectGUI.php.

◆ $requested_glo_ref_id

int ilObjContentObjectGUI::$requested_glo_ref_id = 0
protected

Definition at line 72 of file class.ilObjContentObjectGUI.php.

◆ $requested_hierarchy

bool ilObjContentObjectGUI::$requested_hierarchy = false
protected

Definition at line 69 of file class.ilObjContentObjectGUI.php.

◆ $requested_lang_switch_mode

string ilObjContentObjectGUI::$requested_lang_switch_mode = ""
protected

Definition at line 73 of file class.ilObjContentObjectGUI.php.

◆ $requested_link_ref_id

int ilObjContentObjectGUI::$requested_link_ref_id = 0
protected

Definition at line 76 of file class.ilObjContentObjectGUI.php.

◆ $requested_lm_menu_expand

int ilObjContentObjectGUI::$requested_lm_menu_expand = 0
protected

Definition at line 67 of file class.ilObjContentObjectGUI.php.

◆ $requested_lmexpand

int ilObjContentObjectGUI::$requested_lmexpand = 0
protected

Definition at line 75 of file class.ilObjContentObjectGUI.php.

◆ $requested_lmmovecopy

bool ilObjContentObjectGUI::$requested_lmmovecopy = false
protected

Definition at line 78 of file class.ilObjContentObjectGUI.php.

◆ $requested_menu_entry

int ilObjContentObjectGUI::$requested_menu_entry = 0
protected

Definition at line 66 of file class.ilObjContentObjectGUI.php.

◆ $requested_new_type

string ilObjContentObjectGUI::$requested_new_type = ""
protected

Definition at line 61 of file class.ilObjContentObjectGUI.php.

◆ $requested_obj_id

int ilObjContentObjectGUI::$requested_obj_id = 0
protected

Definition at line 60 of file class.ilObjContentObjectGUI.php.

◆ $requested_ref_id

int ilObjContentObjectGUI::$requested_ref_id = 0
protected

Definition at line 63 of file class.ilObjContentObjectGUI.php.

◆ $requested_root_id

int ilObjContentObjectGUI::$requested_root_id = 0
protected

Definition at line 70 of file class.ilObjContentObjectGUI.php.

◆ $requested_search_root_expand

int ilObjContentObjectGUI::$requested_search_root_expand = 0
protected

Definition at line 68 of file class.ilObjContentObjectGUI.php.

◆ $requested_totransl

string ilObjContentObjectGUI::$requested_totransl = ""
protected

Definition at line 77 of file class.ilObjContentObjectGUI.php.

Referenced by getMultiLangHeader().

◆ $requested_transl

string ilObjContentObjectGUI::$requested_transl = ""
protected

Definition at line 64 of file class.ilObjContentObjectGUI.php.

Referenced by getMultiLangHeader().

◆ $tabs

ilTabsGUI ilObjContentObjectGUI::$tabs
protected

Definition at line 52 of file class.ilObjContentObjectGUI.php.

Referenced by editMenuProperties().

◆ $to_props

bool ilObjContentObjectGUI::$to_props = false
protected

Definition at line 59 of file class.ilObjContentObjectGUI.php.

◆ $ui

ILIAS DI UIServices ilObjContentObjectGUI::$ui
protected

Definition at line 56 of file class.ilObjContentObjectGUI.php.


The documentation for this class was generated from the following file: