ILIAS  release_8 Revision v8.24
ilObjFolderGUI Class Reference

Class ilObjFolderGUI. More...

+ Inheritance diagram for ilObjFolderGUI:
+ Collaboration diagram for ilObjFolderGUI:

Public Member Functions

 __construct ( $a_data, int $a_id=0, bool $a_call_by_reference=true, bool $a_prepare_output=false)
 
 viewObject ()
 viewObject container presentation for "administration -> repository, trash, permissions" More...
 
 renderObject ()
 
 executeCommand ()
 
 setFolderTree (ilTree $a_tree)
 
 showSummaryObject ()
 this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually, if everything works through ilCtrl in the future this may be changed More...
 
 infoScreenObject ()
 this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually, if everything works through ilCtrl in the future this may be changed More...
 
 infoScreen ()
 
 modifyItemGUI (ilObjectListGUI $a_item_list_gui, array $a_item_data)
 
 editObject ()
 
 setSubTabs (string $a_tab)
 
 deleteObject (bool $error=false)
 Display deletion confirmation screen. More...
 
- Public Member Functions inherited from ilContainerGUI
 executeCommand ()
 
 forwardToPageObject ()
 
 addPageTabs ()
 
 getContainerPageHTML ()
 
 prepareOutput (bool $show_subobjects=true)
 
 getContentGUI ()
 
 renderObject ()
 
 renderBlockAsynchObject ()
 render the object More...
 
 setContentSubTabs ()
 
 showAdministrationPanel ()
 
 showPermanentLink ()
 
 editPageFrameObject ()
 
 cancelPageContentObject ()
 
 showLinkListObject ()
 
 clearAdminCommandsDetermination ()
 
 addHeaderRow (ilTemplate $a_tpl, string $a_type, bool $a_show_image=true)
 
 addMessageRow (ilTemplate $a_tpl, string $a_message, string $a_type)
 
 setPageEditorTabs ()
 
 addStandardContainerSubTabs (bool $a_include_view=true)
 Add standard container subtabs for view, manage, oderdering and text/media editor link. More...
 
 enableAdministrationPanelObject ()
 
 disableAdministrationPanelObject ()
 
 editOrderObject ()
 
 isActiveOrdering ()
 
 isActiveItemOrdering ()
 
 enableMultiDownloadObject ()
 
 isMultiDownloadEnabled ()
 
 cutObject ()
 cut object(s) out from a container and write the information to clipboard @access public More...
 
 copyObject ()
 Copy object(s) out from a container and write the information to clipboard It is not possible to copy multiple objects at once. More...
 
 downloadObject ()
 
 getBucketTitle ()
 
 linkObject ()
 create an new reference of an object in tree it's like a hard link of unix More...
 
 clearObject ()
 clear clipboard and go back to last object More...
 
 performPasteIntoMultipleObjectsObject ()
 
 initAndDisplayLinkIntoMultipleObjectsObject ()
 
 showPasteTreeObject ()
 
 cancelMoveLinkObject ()
 Cancel move|link empty clipboard and return to parent. More...
 
 keepObjectsInClipboardObject ()
 
 initAndDisplayCopyIntoMultipleObjectsObject ()
 
 initAndDisplayMoveIntoObjectObject ()
 
 pasteObject ()
 paste object from clipboard to current place Depending on the chosen command the object(s) are linked, copied or moved More...
 
 clipboardObject ()
 
 isActiveAdministrationPanel ()
 
 setColumnSettings (ilColumnGUI $column_gui)
 
 allowBlocksMoving ()
 Standard is to allow blocks moving. More...
 
 allowBlocksConfigure ()
 Standard is to allow blocks configuration. More...
 
 cloneAllObject ()
 Clone all object Overwritten method for copying container objects. More...
 
 saveSortingObject ()
 
 cloneNodes (int $srcRef, int $dstRef, array &$mapping, string $newName=null)
 Recursively clones all nodes of the RBAC tree. More...
 
 modifyItemGUI (ilObjectListGUI $a_item_list_gui, array $a_item_data)
 
 editStylePropertiesObject ()
 
 getAsynchItemListObject ()
 
 redrawListItemObject ()
 Redraw a list item (ajax) More...
 
 trashObject ()
 Show trash content of object. More...
 
 trashApplyFilterObject ()
 
 trashResetFilterObject ()
 
 removeFromSystemObject ()
 
 undeleteObject ()
 Get objects back from trash. More...
 
 confirmRemoveFromSystemObject ()
 
 setSideColumnReturn ()
 
 getAdminTabs ()
 administration tabs show only permissions and trash folder More...
 
 competencesObject ()
 
- Public Member Functions inherited from ilObjectGUI
 __construct ($data, int $id=0, bool $call_by_reference=true, bool $prepare_output=true)
 
 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] don't belong to the current 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...
 
 cancelDeleteObject ()
 cancel deletion of object More...
 
 cancelObject ()
 cancel action and go back to previous page More...
 
 createObject ()
 create new object form More...
 
 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)
 
 redirectAfterCreation ()
 Redirect after creation, see https://docu.ilias.de/goto_docu_wiki_wpage_5035_1357.html Should be overwritten and redirect to settings screen. More...
 
 addToDeskObject ()
 
 removeFromDeskObject ()
 
- Public Member Functions inherited from ILIAS\Object\ImplementsCreationCallback
 callCreationCallback (\ilObject $object, \ilObjectDefinition $obj_definition, int $requested_crtcb)
 
- Public Member Functions inherited from ilDesktopItemHandling
 addToDeskObject ()
 Add desktop item @access public. More...
 
 removeFromDeskObject ()
 Remove from desktop @access public. More...
 

Static Public Member Functions

static _goto ($a_target)
 goto target group More...
 
- Static Public Member Functions inherited from ilContainerGUI
static _buildPath (int $a_ref_id, int $a_course_ref_id)
 build path More...
 
- 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)
 

Data Fields

ilTree $folder_tree
 
- Data Fields inherited from ilContainerGUI
int $bl_cnt = 1
 
bool $multi_download_enabled = false
 
- Data Fields inherited from ilObjectGUI
const ALLOWED_TAGS_IN_TITLE_AND_DESCRIPTION
 
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
 

Protected Member Functions

 importFileObject (?int $parent_id=null)
 
 initEditForm ()
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 updateCustom (ilPropertyFormGUI $form)
 Insert custom update form values into object. More...
 
 afterSave (ilObject $new_object)
 Post (successful) object creation hook. More...
 
 getTabs ()
 @abstract overwrite in derived GUI class of your object type More...
 
 showPossibleSubObjects ()
 show possible sub objects selection list More...
 
 forwardToTimingsView ()
 
- Protected Member Functions inherited from ilContainerGUI
 getEditFormValues ()
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 setTitleAndDescription ()
 
 showPossibleSubObjects ()
 show possible sub objects (pull down menu) More...
 
 supportsPageEditor ()
 
 getTabs ()
 @abstract overwrite in derived GUI class of your object type More...
 
 showContainerPageTabs ()
 
 showPasswordInstructionObject (bool $a_init=true)
 
 initFormPasswordInstruction ()
 Init password form. More...
 
 savePasswordObject ()
 
 initEditForm ()
 
 initSortingForm (ilPropertyFormGUI $form, array $a_sorting_settings)
 Append sorting settings to property form. More...
 
 initListPresentationForm (ilPropertyFormGUI $form)
 Add list presentation settings to form. More...
 
 saveListPresentation (ilPropertyFormGUI $form)
 
 initSortingDirectionForm (ilContainerSortingSettings $sorting_settings, ilRadioOption $element, string $a_prefix)
 Add sorting direction. More...
 
 initManualSortingOptionForm (ilContainerSortingSettings $settings, ilRadioOption $element, string $a_prefix, array $a_sorting_settings)
 Add manual sorting options. More...
 
 saveSortingSettings (ilPropertyFormGUI $form)
 
 trashHandleFilter (bool $action_apply, bool $action_reset)
 
 restoreToNewLocationObject (ilPropertyFormGUI $form=null)
 
 getTreeSelectorGUI (string $cmd)
 
 initFilter ()
 
 showContainerFilter ()
 
- Protected Member Functions inherited from ilObjectGUI
 getObjectService ()
 
 assignObject ()
 
 setTitleAndDescription ()
 
 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...
 
 initCreationForms (string $new_type)
 Init creation forms. More...
 
 getCreationFormsHTML (array $forms)
 Get HTML for creation forms (accordion) More...
 
 initCreateForm (string $new_type)
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 
 addDidacticTemplateOptions (array &$a_options)
 Add custom templates. More...
 
 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...
 
 initImportForm (string $new_type)
 
 importFileObject (int $parent_id=null)
 
 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...
 
 fillCloneTemplate (?string $tpl_name, string $type)
 Fill object clone template This method can be called from any object GUI class that wants to offer object cloning. 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...
 
 showCustomIconsEditing ( $input_colspan=1, ilPropertyFormGUI $form=null, $as_section=true)
 show edit section of custom icons for container More...
 

Protected Attributes

ilHelpGUI $help
 
StandardGUIRequest $folder_request
 
- Protected Attributes inherited from ilContainerGUI
ILIAS Style Content GUIService $content_style_gui
 
ilRbacSystem $rbacsystem
 
ilRbacReview $rbacreview
 
ilTabsGUI $tabs
 
ilErrorHandling $error
 
ilObjectDefinition $obj_definition
 
ilRbacAdmin $rbacadmin
 
ilPropertyFormGUI $form
 
ilLogger $log
 
ilObjectDataCache $obj_data_cache
 
Services $global_screen
 
ilAppEventHandler $app_event_handler
 
UIServices $ui
 
ilContainerFilterService $container_filter_service
 
ilContainerUserFilter $container_user_filter = null
 
Standard $ui_filter = null
 
bool $edit_order = false
 
bool $adminCommands = false
 
string $requested_redirectSource = ""
 
int $current_position = 0
 
ClipboardManager $clipboard
 
StandardGUIRequest $std_request
 
ViewManager $view_manager
 
ilComponentFactory $component_factory
 
ILIAS Style Content DomainService $content_style_domain
 
- Protected Attributes inherited from ilObjectGUI
ILIAS Notes Service $notes_service
 
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
 
Factory $refinery
 
ilFavouritesManager $favourites
 
ilObjectCustomIconFactory $custom_icon_factory
 
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 = ""
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilObjFolderGUI::__construct (   $data,
int  $id = 0,
bool  $call_by_reference = true,
bool  $prepare_output = false 
)
Parameters
mixed$data
int$id
bool$call_by_reference
bool$prepare_output
Exceptions
ilCtrlException

Reimplemented from ilObjectGUI.

Definition at line 38 of file class.ilObjFolderGUI.php.

43 {
44 global $DIC;
45
46 $this->tree = $DIC->repositoryTree();
47 $this->tabs = $DIC->tabs();
48 $this->user = $DIC->user();
49 $this->ctrl = $DIC->ctrl();
50 $this->lng = $DIC->language();
51 $this->access = $DIC->access();
52 $this->rbacsystem = $DIC->rbac()->system();
53 $this->help = $DIC["ilHelp"];
54 $this->error = $DIC["ilErr"];
55 $this->tpl = $DIC["tpl"];
56 $this->settings = $DIC->settings();
57 $this->type = "fold";
58 parent::__construct($a_data, $a_id, $a_call_by_reference, $a_prepare_output);
59 $this->lng->loadLanguageModule("obj");
60 $this->folder_request = $DIC
61 ->folder()
62 ->internal()
63 ->gui()
64 ->standardRequest();
65 }
error(string $a_errmsg)
global $DIC
Definition: feed.php:28
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc

References $DIC, ILIAS\GlobalScreen\Provider\__construct(), ILIAS\Repository\access(), ILIAS\Repository\ctrl(), error(), ILIAS\Repository\help(), ILIAS\Repository\lng(), ILIAS\Repository\settings(), ILIAS\Repository\tabs(), and ILIAS\Repository\user().

+ Here is the call graph for this function:

Member Function Documentation

◆ _goto()

static ilObjFolderGUI::_goto (   $a_target)
static

goto target group

Definition at line 492 of file class.ilObjFolderGUI.php.

492 : void
493 {
494 global $DIC;
495
496 $ilAccess = $DIC->access();
497 $ilErr = $DIC["ilErr"];
498 $lng = $DIC->language();
499
500 $a_target = (int) $a_target;
501
502 if ($ilAccess->checkAccess("read", "", $a_target)) {
504 }
505 if ($ilAccess->checkAccess("visible", "", $a_target)) {
506 ilObjectGUI::_gotoRepositoryNode($a_target, "infoScreen");
507 }
508 $ilErr->raiseError($lng->txt("msg_no_perm_read"), $ilErr->FATAL);
509 }
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
static _gotoRepositoryNode(int $ref_id, string $cmd="")
ilLanguage $lng
$ilErr
Definition: raiseError.php:17

References $DIC, $ilErr, ilObjectGUI\$lng, ilObjectGUI\_gotoRepositoryNode(), ILIAS\Repository\int(), and ilLanguage\txt().

+ Here is the call graph for this function:

◆ afterSave()

ilObjFolderGUI::afterSave ( ilObject  $new_object)
protected

Post (successful) object creation hook.

Reimplemented from ilObjectGUI.

Definition at line 346 of file class.ilObjFolderGUI.php.

346 : void
347 {
348 $sort = new ilContainerSortingSettings($new_object->getId());
349 $sort->setSortMode(ilContainer::SORT_INHERIT);
350 $sort->update();
351
352 // always send a message
353 $this->tpl->setOnScreenMessage('success', $this->lng->txt("fold_added"), true);
354 $this->ctrl->setParameter($this, "ref_id", $new_object->getRefId());
355 $this->redirectToRefId($new_object->getRefId(), "");
356 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
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 sav...

References ILIAS\Repository\ctrl(), ilObject\getId(), ilObject\getRefId(), ILIAS\Repository\lng(), ilObjectGUI\redirectToRefId(), and ilContainer\SORT_INHERIT.

+ Here is the call graph for this function:

◆ deleteObject()

ilObjFolderGUI::deleteObject ( bool  $error = false)

Display deletion confirmation screen.

Only for referenced objects. For user,role & rolt overwrite this function in the appropriate Object folders classes (ilObjUserFolderGUI,ilObjRoleFolderGUI)

Reimplemented from ilObjectGUI.

Definition at line 604 of file class.ilObjFolderGUI.php.

604 : void
605 {
606 $this->tabs_gui->activateTab('view_content');
607 parent::deleteObject($error);
608 }
ilErrorHandling $error

References ilContainerGUI\$error.

◆ editObject()

ilObjFolderGUI::editObject ( )

Reimplemented from ilObjectGUI.

Definition at line 563 of file class.ilObjFolderGUI.php.

563 : void
564 {
565 $ilTabs = $this->tabs;
567
568 $this->setSubTabs("settings");
569 $ilTabs->activateTab("settings");
570
571 if (!$this->checkPermissionBool("write")) {
572 $ilErr->raiseError($this->lng->txt("msg_no_perm_write"), $ilErr->MESSAGE);
573 }
574
575 $form = $this->initEditForm();
576 $values = $this->getEditFormValues();
577 if ($values) {
578 $form->setValuesByArray($values, true);
579 }
580 $GLOBALS['tpl']->setContent($form->getHTML());
581 }
if(!defined('PATH_SEPARATOR')) $GLOBALS['_PEAR_default_error_mode']
Definition: PEAR.php:64
ilPropertyFormGUI $form
setSubTabs(string $a_tab)
checkPermissionBool(string $perm, string $cmd="", string $type="", ?int $ref_id=null)
setValuesByArray(array $a_values, bool $a_restrict_to_value_keys=false)

References ilContainerGUI\$error, ilContainerGUI\$form, $GLOBALS, $ilErr, ilContainerGUI\$tabs, ilObjectGUI\checkPermissionBool(), ilContainerGUI\getEditFormValues(), ilPropertyFormGUI\getHTML(), initEditForm(), ILIAS\Repository\lng(), setSubTabs(), and ilPropertyFormGUI\setValuesByArray().

+ Here is the call graph for this function:

◆ executeCommand()

ilObjFolderGUI::executeCommand ( )

Reimplemented from ilContainerGUI.

Definition at line 98 of file class.ilObjFolderGUI.php.

98 : void
99 {
101 $next_class = $this->ctrl->getNextClass($this);
102 $cmd = $this->ctrl->getCmd();
103
104 $header_action = true;
105 switch ($next_class) {
106 case strtolower(ilRepositoryTrashGUI::class):
107 $ru = new ilRepositoryTrashGUI($this);
108 $this->ctrl->setReturn($this, 'trash');
109 $this->ctrl->forwardCommand($ru);
110 break;
111
112 case 'ilpermissiongui':
113 $this->prepareOutput();
114 $this->tabs_gui->activateTab('perm_settings');
115 $perm_gui = new ilPermissionGUI($this);
116 $ret = $this->ctrl->forwardCommand($perm_gui);
117 break;
118
119
120 case 'ilcoursecontentgui':
121 $this->prepareOutput();
122 $course_content_obj = new ilCourseContentGUI($this);
123 $this->ctrl->forwardCommand($course_content_obj);
124 break;
125
126 case "illearningprogressgui":
127 $this->prepareOutput();
128
129 $new_gui = new ilLearningProgressGUI(
131 $this->object->getRefId(),
132 $this->folder_request->getUserId() ?: $ilUser->getId()
133 );
134 $this->ctrl->forwardCommand($new_gui);
135 $this->tabs_gui->setTabActive('learning_progress');
136 break;
137
138 // container page editing
139 case "ilcontainerpagegui":
140 $this->prepareOutput(false);
141 $ret = $this->forwardToPageObject();
142 if ($ret !== "") {
143 $this->tpl->setContent($ret);
144 }
145 $header_action = false;
146 break;
147
148 case 'ilinfoscreengui':
149 $this->prepareOutput();
150 $this->infoScreen();
151 break;
152
153 case 'ilobjectcopygui':
154 $this->prepareOutput();
155
156 $cp = new ilObjectCopyGUI($this);
157 $cp->setType('fold');
158 $this->ctrl->forwardCommand($cp);
159 break;
160
161 case "ilobjectcontentstylesettingsgui":
162 $this->checkPermission("write");
163 $this->setTitleAndDescription();
164 $this->showContainerPageTabs();
165 $settings_gui = $this->content_style_gui
166 ->objectSettingsGUIForRefId(
167 null,
168 $this->object->getRefId()
169 );
170 $this->ctrl->forwardCommand($settings_gui);
171 break;
172
173 case 'ilexportgui':
174 $this->prepareOutput();
175
176 $this->tabs_gui->setTabActive('export');
177 $exp = new ilExportGUI($this);
178 $exp->addFormat('xml');
179 $this->ctrl->forwardCommand($exp);
180 break;
181
182 case "ilcommonactiondispatchergui":
183 $this->prepareOutput();
185 $this->ctrl->forwardCommand($gui);
186 break;
187
188 case 'ildidactictemplategui':
189 $this->ctrl->setReturn($this, 'edit');
190 $did = new ilDidacticTemplateGUI($this);
191 $this->ctrl->forwardCommand($did);
192 break;
193 case 'ilcolumngui':
194 $this->tabs_gui->setTabActive('none');
195 $this->checkPermission("read");
196 $this->viewObject();
197 break;
198
199 case 'ilobjecttranslationgui':
200 $this->checkPermissionBool("write");
201 $this->prepareOutput();
202 $this->setSubTabs("settings_trans");
203 $transgui = new ilObjectTranslationGUI($this);
204 $this->ctrl->forwardCommand($transgui);
205 break;
206
207 default:
208
209 $this->prepareOutput();
210 // cognos-blu-patch: begin
211 // removed timings forward
212 // cognos-blu-patch: end
213
214 if (empty($cmd)) {
215 $cmd = "view";
216 }
217 $cmd .= "Object";
218 $this->$cmd();
219 break;
220 }
221
222 if ($header_action) {
223 $this->addHeaderAction();
224 }
225 }
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
prepareOutput(bool $show_subobjects=true)
Class ilCourseContentGUI.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
viewObject()
viewObject container presentation for "administration -> repository, trash, permissions"
GUI class for the workflow of copying objects.
checkPermission(string $perm, string $cmd="", string $type="", ?int $ref_id=null)
addHeaderAction()
Add header action menu.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
Repository GUI Utilities.
$ilUser
Definition: imgupload.php:34

References $ilUser, ilObjectGUI\$user, ilObjectGUI\addHeaderAction(), ilObjectGUI\checkPermission(), ilObjectGUI\checkPermissionBool(), ILIAS\Repository\ctrl(), ilContainerGUI\forwardToPageObject(), ilCommonActionDispatcherGUI\getInstanceFromAjaxCall(), infoScreen(), ilLearningProgressBaseGUI\LP_CONTEXT_REPOSITORY, ILIAS\Repository\object(), ilContainerGUI\prepareOutput(), setSubTabs(), ilContainerGUI\setTitleAndDescription(), ilContainerGUI\showContainerPageTabs(), and viewObject().

+ Here is the call graph for this function:

◆ forwardToTimingsView()

ilObjFolderGUI::forwardToTimingsView ( )
protected

Definition at line 540 of file class.ilObjFolderGUI.php.

540 : void
541 {
543
544 if (!$crs_ref = $tree->checkForParentType($this->ref_id, 'crs')) {
545 return;
546 }
548 if (!ilSession::has('crs_timings')) {
549 ilSession::set('crs_timings', true);
550 }
551
552 if (ilSession::get('crs_timings')) {
553 $course_content_obj = new ilCourseContentGUI($this);
554 $this->ctrl->setCmdClass(get_class($course_content_obj));
555 $this->ctrl->setCmd('editUserTimings');
556 $this->ctrl->forwardCommand($course_content_obj);
557 return;
558 }
559 }
560 ilSession::set('crs_timings', false);
561 }
static _lookupViewMode(int $a_id)
static _lookupObjId(int $ref_id)
static get(string $a_var)
static set(string $a_var, $a_val)
Set a value.
static has($a_var)
checkForParentType(int $a_ref_id, string $a_type, bool $a_exclude_source_check=false)
Check for parent type e.g check if a folder (ref_id 3) is in a parent course obj => checkForParentTyp...

References ilObjectGUI\$tree, ilObject\_lookupObjId(), ilObjCourse\_lookupViewMode(), ilTree\checkForParentType(), ILIAS\Repository\ctrl(), ilSession\get(), ilSession\has(), ilSession\set(), and ilContainer\VIEW_TIMING.

+ Here is the call graph for this function:

◆ getEditFormCustomValues()

ilObjFolderGUI::getEditFormCustomValues ( array &  $a_values)
protected

Add values to custom edit fields.

Reimplemented from ilObjectGUI.

Definition at line 304 of file class.ilObjFolderGUI.php.

304 : void
305 {
306 // we cannot use $this->object->getOrderType()
307 // if set to inherit it will be translated to parent setting
308 $sort = new ilContainerSortingSettings($this->object->getId());
309 $a_values["sor"] = $sort->getSortMode();
310 }

References ILIAS\Repository\object().

+ Here is the call graph for this function:

◆ getTabs()

ilObjFolderGUI::getTabs ( )
protected

@abstract overwrite in derived GUI class of your object type

Reimplemented from ilContainerGUI.

Definition at line 411 of file class.ilObjFolderGUI.php.

411 : void
412 {
415 $ilCtrl = $this->ctrl;
416 $ilAccess = $this->access;
417 $ilHelp = $this->help;
418
419 $this->ctrl->setParameter($this, "ref_id", $this->ref_id);
420
421 $ilHelp->setScreenIdComponent("fold");
422
423 $this->tabs_gui->setTabActive("");
424 if ($ilAccess->checkAccess('read', '', $this->ref_id)) {
425 $this->tabs_gui->addTab(
426 "view_content",
427 $lng->txt("content"),
428 $this->ctrl->getLinkTarget($this, "")
429 );
430
431 //BEGIN ChangeEvent add info tab to category object
432 $force_active = $this->ctrl->getNextClass() === "ilinfoscreengui"
433 || strtolower($this->ctrl->getCmdClass()) === "ilnotegui";
434 $this->tabs_gui->addTarget(
435 "info_short",
436 $this->ctrl->getLinkTargetByClass(
437 ["ilobjfoldergui", "ilinfoscreengui"],
438 "showSummary"
439 ),
440 ["showSummary", "", "infoScreen"],
441 "",
442 "",
443 $force_active
444 );
445 //END ChangeEvent add info tab to category object
446 }
447
448 if ($rbacsystem->checkAccess('write', $this->ref_id)) {
449 $this->tabs_gui->addTarget(
450 "settings",
451 $this->ctrl->getLinkTarget($this, "edit"),
452 "edit",
453 "",
454 "",
455 ($ilCtrl->getCmd() === "edit")
456 );
457 }
458
459 // learning progress
460 if (ilLearningProgressAccess::checkAccess($this->object->getRefId())) {
461 $this->tabs_gui->addTarget(
462 'learning_progress',
463 $this->ctrl->getLinkTargetByClass(['ilobjfoldergui', 'illearningprogressgui'], ''),
464 '',
465 ['illplistofobjectsgui', 'illplistofsettingsgui', 'illearningprogressgui', 'illplistofprogressgui']
466 );
467 }
468
469 if ($ilAccess->checkAccess('write', '', $this->object->getRefId())) {
470 $this->tabs_gui->addTarget(
471 'export',
472 $this->ctrl->getLinkTargetByClass('ilexportgui', ''),
473 'export',
474 'ilexportgui'
475 );
476 }
477
478
479 if ($rbacsystem->checkAccess('edit_permission', $this->ref_id)) {
480 $this->tabs_gui->addTarget(
481 "perm_settings",
482 $this->ctrl->getLinkTargetByClass([get_class($this), 'ilpermissiongui'], "perm"),
483 ["perm", "info", "owner"],
484 'ilpermissiongui'
485 );
486 }
487 }
ilRbacSystem $rbacsystem
static checkAccess(int $a_ref_id, bool $a_allow_only_read=true)
check access to learning progress
ilAccessHandler $access
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 ilObjectGUI\$access, ilObjectGUI\$ctrl, $help, ilObjectGUI\$lng, ilContainerGUI\$rbacsystem, ilLearningProgressAccess\checkAccess(), ilRbacSystem\checkAccess(), ILIAS\Repository\ctrl(), ILIAS\Repository\object(), and ilLanguage\txt().

+ Here is the call graph for this function:

◆ importFileObject()

ilObjFolderGUI::importFileObject ( ?int  $parent_id = null)
protected

Definition at line 232 of file class.ilObjFolderGUI.php.

232 : void
233 {
235
236 parent::importFileObject($parent_id);
237
238 $this->tpl->setOnScreenMessage('success', $lng->txt("msg_obj_modified"), true);
239 $this->ctrl->returnToParent($this);
240 }

References ilObjectGUI\$lng, ILIAS\Repository\ctrl(), and ilLanguage\txt().

+ Here is the call graph for this function:

◆ infoScreen()

ilObjFolderGUI::infoScreen ( )
Exceptions
ilPermissionException

Definition at line 373 of file class.ilObjFolderGUI.php.

373 : void
374 {
375 $ilAccess = $this->access;
376
377 if (!$ilAccess->checkAccess("visible", "", $this->ref_id)) {
378 throw new ilPermissionException($this->lng->txt("msg_no_perm_read"));
379 }
380
381 $info = new ilInfoScreenGUI($this);
382
383 $GLOBALS['ilTabs']->activateTab('info_short');
384
385 $info->enablePrivateNotes();
386
387 if ($ilAccess->checkAccess("read", "", $this->requested_ref_id)) {
388 $info->enableNews();
389 }
390
391 // no news editing for files, just notifications
392 $info->enableNewsEditing(false);
393 if ($ilAccess->checkAccess("write", "", $this->requested_ref_id)) {
394 $news_set = new ilSetting("news");
395 $enable_internal_rss = $news_set->get("enable_rss_for_internal");
396
397 if ($enable_internal_rss) {
398 $info->setBlockProperty("news", "settings", '1');
399 $info->setBlockProperty("news", "public_notifications_option", '1');
400 }
401 }
402
403
404 // standard meta data
405 $info->addMetaDataSections($this->object->getId(), 0, $this->object->getType());
406
407 // forward the command
408 $this->ctrl->forwardCommand($info);
409 }
Class ilInfoScreenGUI.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References ilObjectGUI\$access, $GLOBALS, ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ILIAS\Repository\object().

Referenced by executeCommand(), infoScreenObject(), and showSummaryObject().

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

◆ infoScreenObject()

ilObjFolderGUI::infoScreenObject ( )

this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually, if everything works through ilCtrl in the future this may be changed

Definition at line 363 of file class.ilObjFolderGUI.php.

363 : void
364 {
365 $this->ctrl->setCmd("showSummary");
366 $this->ctrl->setCmdClass("ilinfoscreengui");
367 $this->infoScreen();
368 }

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

+ Here is the call graph for this function:

◆ initEditForm()

ilObjFolderGUI::initEditForm ( )
protected

Reimplemented from ilContainerGUI.

Definition at line 242 of file class.ilObjFolderGUI.php.

243 {
245 $obj_service = $this->getObjectService();
246
247 $lng->loadLanguageModule($this->object->getType());
248
249 $form = new ilPropertyFormGUI();
250 $form->setFormAction($this->ctrl->getFormAction($this, "update"));
251 $form->setTitle($this->lng->txt($this->object->getType() . "_edit"));
252
253 // title
254 $ti = new ilTextInputGUI($this->lng->txt("title"), "title");
255 $ti->setSize(min(40, ilObject::TITLE_LENGTH));
256 $ti->setMaxLength(ilObject::TITLE_LENGTH);
257 $ti->setRequired(true);
258 $form->addItem($ti);
259
260 // description
261 $ta = new ilTextAreaInputGUI($this->lng->txt("description"), "desc");
262 $ta->setCols(40);
263 $ta->setRows(2);
264 $form->addItem($ta);
265
266 // Show didactic template type
268
269 $pres = new ilFormSectionHeaderGUI();
270 $pres->setTitle($this->lng->txt('fold_presentation'));
271 $form->addItem($pres);
272
273 // title and icon visibility
274 $form = $obj_service->commonSettings()->legacyForm($form, $this->object)->addTitleIconVisibility();
275
276 // top actions visibility
277 $form = $obj_service->commonSettings()->legacyForm($form, $this->object)->addTopActionsVisibility();
278
279 // custom icon
280 $form = $obj_service->commonSettings()->legacyForm($form, $this->object)->addIcon();
281
282 // tile image
283 $form = $obj_service->commonSettings()->legacyForm($form, $this->object)->addTileImage();
284
285 // list presentation
287
288 $this->initSortingForm(
289 $form,
290 [
295 ]
296 );
297
298 $form->addCommandButton("update", $this->lng->txt("save"));
299 //$this->form->addCommandButton("cancelUpdate", $lng->txt("cancel"));
300
301 return $form;
302 }
initSortingForm(ilPropertyFormGUI $form, array $a_sorting_settings)
Append sorting settings to property form.
initListPresentationForm(ilPropertyFormGUI $form)
Add list presentation settings to form.
setFormAction(string $a_formaction)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
loadLanguageModule(string $a_module)
Load language module.
initDidacticTemplate(ilPropertyFormGUI $form)
const TITLE_LENGTH
This class represents a property form user interface.
addCommandButton(string $a_cmd, string $a_text, string $a_id="")
This class represents a text area property in a property form.
This class represents a text property in a property form.

References ilContainerGUI\$form, ilObjectGUI\$lng, ilPropertyFormGUI\addCommandButton(), ilPropertyFormGUI\addItem(), ILIAS\Repository\ctrl(), ilObjectGUI\getObjectService(), ilObjectGUI\initDidacticTemplate(), ilContainerGUI\initListPresentationForm(), ilContainerGUI\initSortingForm(), ILIAS\Repository\lng(), ilLanguage\loadLanguageModule(), ILIAS\Repository\object(), ilFormGUI\setFormAction(), ilPropertyFormGUI\setTitle(), ilContainer\SORT_CREATION, ilContainer\SORT_INHERIT, ilContainer\SORT_MANUAL, ilContainer\SORT_TITLE, and ilObject\TITLE_LENGTH.

Referenced by editObject().

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

◆ modifyItemGUI()

ilObjFolderGUI::modifyItemGUI ( ilObjectListGUI  $a_item_list_gui,
array  $a_item_data 
)

Reimplemented from ilContainerGUI.

Definition at line 511 of file class.ilObjFolderGUI.php.

511 : void
512 {
514
515 // if folder is in a course, modify item list gui according to course requirements
516 if ($course_ref_id = $tree->checkForParentType($this->object->getRefId(), 'crs')) {
517 $course_obj_id = ilObject::_lookupObjId($course_ref_id);
519 $a_item_list_gui,
520 'ilcoursecontentgui',
521 $a_item_data,
522 ilObjCourse::_lookupAboStatus($course_obj_id),
523 $course_ref_id,
524 $course_obj_id,
525 $this->object->getRefId()
526 );
527 }
528 }
static _modifyItemGUI(ilObjectListGUI $a_item_list_gui, string $a_cmd_class, array $a_item_data, bool $a_abo_status, int $a_course_ref_id, int $a_course_obj_id, int $a_parent_ref_id=0)
static _lookupAboStatus(int $a_id)

References ilObjectGUI\$tree, ilObjCourse\_lookupAboStatus(), ilObject\_lookupObjId(), ilObjCourseGUI\_modifyItemGUI(), ilTree\checkForParentType(), and ILIAS\Repository\object().

+ Here is the call graph for this function:

◆ renderObject()

ilObjFolderGUI::renderObject ( )

Reimplemented from ilContainerGUI.

Definition at line 88 of file class.ilObjFolderGUI.php.

88 : void
89 {
90 $ilTabs = $this->tabs;
91
92 $this->checkPermission('read');
93
94 $ilTabs->activateTab("view_content");
95 parent::renderObject();
96 }

References ilContainerGUI\$tabs, and ilObjectGUI\checkPermission().

Referenced by viewObject().

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

◆ setFolderTree()

ilObjFolderGUI::setFolderTree ( ilTree  $a_tree)

Definition at line 227 of file class.ilObjFolderGUI.php.

227 : void
228 {
229 $this->folder_tree = $a_tree;
230 }

◆ setSubTabs()

ilObjFolderGUI::setSubTabs ( string  $a_tab)

Definition at line 583 of file class.ilObjFolderGUI.php.

583 : void
584 {
585 $ilTabs = $this->tabs;
587
588 $ilTabs->addSubTab(
589 "settings",
590 $lng->txt("fold_settings"),
591 $this->ctrl->getLinkTarget($this, 'edit')
592 );
593
594 $this->tabs_gui->addSubTab(
595 "settings_trans",
596 $this->lng->txt("obj_multilinguality"),
597 $this->ctrl->getLinkTargetByClass("ilobjecttranslationgui", "")
598 );
599
600 $ilTabs->activateSubTab($a_tab);
601 $ilTabs->activateTab("settings");
602 }

References ilObjectGUI\$lng, ilContainerGUI\$tabs, ILIAS\Repository\lng(), and ilLanguage\txt().

Referenced by editObject(), and executeCommand().

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

◆ showPossibleSubObjects()

ilObjFolderGUI::showPossibleSubObjects ( )
protected

show possible sub objects selection list

Reimplemented from ilContainerGUI.

Definition at line 533 of file class.ilObjFolderGUI.php.

533 : void
534 {
535 $gui = new ilObjectAddNewItemGUI($this->object->getRefId());
536 $gui->render();
537 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References ILIAS\Repository\object().

+ Here is the call graph for this function:

◆ showSummaryObject()

ilObjFolderGUI::showSummaryObject ( )

this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually, if everything works through ilCtrl in the future this may be changed

Definition at line 339 of file class.ilObjFolderGUI.php.

339 : void
340 {
341 $this->ctrl->setCmd("showSummary");
342 $this->ctrl->setCmdClass("ilinfoscreengui");
343 $this->infoScreen();
344 }

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

+ Here is the call graph for this function:

◆ updateCustom()

ilObjFolderGUI::updateCustom ( ilPropertyFormGUI  $form)
protected

Insert custom update form values into object.

Reimplemented from ilObjectGUI.

Definition at line 312 of file class.ilObjFolderGUI.php.

312 : void
313 {
314 $obj_service = $this->getObjectService();
315
316 // title icon visibility
317 $obj_service->commonSettings()->legacyForm($form, $this->object)->saveTitleIconVisibility();
318
319 // top actions visibility
320 $obj_service->commonSettings()->legacyForm($form, $this->object)->saveTopActionsVisibility();
321
322 // custom icon
323 $obj_service->commonSettings()->legacyForm($form, $this->object)->saveIcon();
324
325 // tile image
326 $obj_service->commonSettings()->legacyForm($form, $this->object)->saveTileImage();
327
328 // list presentation
329 $this->saveListPresentation($form);
330
331 $this->saveSortingSettings($form);
332 }
saveListPresentation(ilPropertyFormGUI $form)
saveSortingSettings(ilPropertyFormGUI $form)

References ilContainerGUI\$form, ilObjectGUI\getObjectService(), ilContainerGUI\saveListPresentation(), and ilContainerGUI\saveSortingSettings().

+ Here is the call graph for this function:

◆ viewObject()

ilObjFolderGUI::viewObject ( )

viewObject container presentation for "administration -> repository, trash, permissions"

Reimplemented from ilObjectGUI.

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

68 : void
69 {
70 $this->checkPermission('read');
71 if (strtolower($this->folder_request->getBaseClass()) === "iladministrationgui") {
72 parent::viewObject();
73 return;
74 }
75
76 // Trac access - see ilObjCourseGUI
78 $GLOBALS["ilUser"]->getId(),
79 $this->object->getId(),
80 $this->object->getRefId(),
81 'fold'
82 );
83
84 $this->renderObject();
85 $this->tabs_gui->setTabActive('view_content');
86 }
static _tracProgress(int $a_user_id, int $a_obj_id, int $a_ref_id, string $a_obj_type='')

References $GLOBALS, ilLearningProgress\_tracProgress(), ilObjectGUI\checkPermission(), ILIAS\Survey\Mode\getId(), ILIAS\Repository\object(), and renderObject().

Referenced by executeCommand().

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

Field Documentation

◆ $folder_request

StandardGUIRequest ilObjFolderGUI::$folder_request
protected

Definition at line 36 of file class.ilObjFolderGUI.php.

◆ $folder_tree

ilTree ilObjFolderGUI::$folder_tree

Definition at line 35 of file class.ilObjFolderGUI.php.

◆ $help

ilHelpGUI ilObjFolderGUI::$help
protected

Definition at line 34 of file class.ilObjFolderGUI.php.

Referenced by getTabs().


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