ILIAS  release_7 Revision v7.30-3-g800a261c036
ilObjOrgUnitGUI Class Reference

Class ilObjOrgUnit GUI class. More...

+ Inheritance diagram for ilObjOrgUnitGUI:
+ Collaboration diagram for ilObjOrgUnitGUI:

Public Member Functions

 __construct ()
 
 executeCommand ()
 
 view ()
 
 showPossibleSubObjects ()
 show possible sub objects selection list More...
 
 setTitleAndDescription ()
 called by prepare output More...
 
 getTabs ()
 
 setContentSubTabs ()
 Set content sub tabs. More...
 
 editSettings ()
 
 updateSettings ()
 
 getAdminTabs ()
 
 performPaste ()
 @description Prepare $_POST for the generic method performPasteIntoMultipleObjectsObject More...
 
 doUserAutoCompleteObject ()
 ?? More...
 
__initTableGUI ()
 
 confirmedDeleteObject ()
 confirmed deletion of org units -> org units are deleted immediately, without putting them to the trash More...
 
 deleteObject ($a_error=false)
 Display deletion confirmation screen for Org Units. More...
 
 __setTableGUIBasicData (&$tbl, &$result_set, $a_from="")
 
 cancelMoveLinkObject ()
 Cancel move|link empty clipboard and return to parent. More...
 
- Public Member Functions inherited from ilContainerGUI
 __construct ($a_data, $a_id, $a_call_by_reference=true, $a_prepare_output=true)
 Constructor @access public. More...
 
 executeCommand ()
 execute command note: this method is overwritten in all container objects More...
 
 forwardToStyleSheet ()
 Forward to style object. More...
 
forwardToPageObject ()
 forward command to page object More...
 
 addPageTabs ()
 Add page tabs. More...
 
 getContainerPageHTML ()
 Get container page HTML. More...
 
 prepareOutput ($a_show_subobjects=true)
 prepare output More...
 
 showTreeFlatIcon ()
 
 setTitleAndDescription ()
 called by prepare output More...
 
 showPossibleSubObjects ()
 show possible sub objects selection list More...
 
 getContentGUI ()
 Get content gui object. More...
 
 renderObject ()
 render the object More...
 
 renderBlockAsynchObject ()
 render the object More...
 
 setContentSubTabs ()
 Set content sub tabs. More...
 
 showAdministrationPanel ()
 show administration panel More...
 
 __showTimingsButton (&$tpl)
 
 showPermanentLink ()
 show permanent link More...
 
 switchToStdEditorObject ()
 Switch to standard page editor. More...
 
 switchToOldEditorObject ()
 Switch to old page editor. More...
 
 useNewEditorObject ()
 Use new editor (-> delete xhtml content page) More...
 
 editPageFrameObject ()
 show page editor frameset More...
 
 editPageContentObject ()
 edit page content (for repository root node and categories) More...
 
 savePageContentObject ()
 
 cancelPageContentObject ()
 
 showLinkListObject ()
 
 clearAdminCommandsDetermination ()
 cleaer administration commands determination More...
 
newBlockTemplate ()
 determin admin commands More...
 
 addHeaderRow (&$a_tpl, $a_type, $a_show_image=true)
 adds a header row to a block template More...
 
 addMessageRow (&$a_tpl, $a_message, $a_type)
 add message row More...
 
 resetRowType ()
 
 setPageEditorTabs ()
 Add page editor tabs. More...
 
 addStandardContainerSubTabs ($a_include_view=true)
 Add standar container subtabs for view, manage, oderdering and text/media editor link. More...
 
 getTabs ()
 common tabs for all container objects (should be called at the end of child getTabs() method More...
 
 enableAdministrationPanelObject ()
 enable administration panel More...
 
 disableAdministrationPanelObject ()
 enable administration panel More...
 
 editOrderObject ()
 Edit order. More...
 
 isActiveOrdering ()
 Check if ordering is enabled. More...
 
 isActiveItemOrdering ()
 Check if item ordering is enabled. More...
 
 enableMultiDownloadObject ()
 
 isMultiDownloadEnabled ()
 
 cutObject ()
 cut object(s) out from a container and write the information to clipboard 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 ()
 get proper label to add in the background task popover More...
 
 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 ()
 Show paste tree. More...
 
 cancelMoveLinkObject ()
 Cancel move|link empty clipboard and return to parent. More...
 
 keepObjectsInClipboardObject ()
 Keep objects in the clipboard. More...
 
 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 ()
 show clipboard More...
 
 isActiveAdministrationPanel ()
 
 setColumnSettings (ilColumnGUI $column_gui)
 May be overwritten in subclasses. More...
 
 allowBlocksMoving ()
 Standard is to allow blocks moving. More...
 
 allowBlocksConfigure ()
 Standard is to allow blocks configuration. More...
 
 cloneWizardPageTreeObject ()
 @access public More...
 
 cloneWizardPageListObject ()
 @access public More...
 
 cloneWizardPageObject ($a_tree_view=true)
 Show clone wizard page for container objects. More...
 
 cloneAllObject ()
 Clone all object Overwritten method for copying container objects. More...
 
 saveSortingObject ()
 Save Sorting. More...
 
 cloneNodes ($srcRef, $dstRef, &$mapping, $newName=null)
 Recursively clones all nodes of the RBAC tree. More...
 
 modifyItemGUI ($a_item_list_gui, $a_item_data, $a_show_path)
 Modify list gui for presentation in container. More...
 
 editStylePropertiesObject ()
 Edit style properties. More...
 
 initStylePropertiesForm ()
 Init style properties form. More...
 
 createStyleObject ()
 Create Style. More...
 
 editStyleObject ()
 Edit Style. More...
 
 deleteStyleObject ()
 Delete Style. More...
 
 saveStyleSettingsObject ()
 Save style settings. More...
 
 getAsynchItemListObject ()
 Get item list command drop down asynchronously. More...
 
 redrawListItemObject ()
 Redraw a list item (ajax) More...
 
 trashObject ()
 Show trash content of object. More...
 
 trashApplyFilterObject ()
 trash table apply filter More...
 
 trashResetFilterObject ()
 trash table reset filter More...
 
 removeFromSystemObject ()
 remove objects from trash bin and all entries therefore every object needs a specific deleteObject() method More...
 
 undeleteObject ()
 Get objects back from trash. More...
 
 confirmRemoveFromSystemObject ()
 confirmation screen remove from system More...
 
 setSideColumnReturn ()
 Set return point for side column actions. More...
 
 getAdminTabs ()
 administration tabs show only permissions and trash folder More...
 
 competencesObject ()
 Redirect to competences. More...
 
- Public Member Functions inherited from ilObjectGUI
 executeCommand ()
 execute command More...
 
 withReferences ()
 determines wether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode ($a_mode=true)
 if true, a creation screen is displayed the current $_GET[ref_id] don't belong to the current class! the mode is determined in ilrepositorygui More...
 
 getCreationMode ()
 get creation mode More...
 
 prepareOutput ($a_show_subobjects=true)
 prepare output More...
 
 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 @access public More...
 
 createObject ()
 create new object form More...
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 save object More...
 
 getDidacticTemplateVar ($a_type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $a_obj, $a_parent_node_id=null)
 Add object to tree at given position. More...
 
 editObject ()
 edit object More...
 
 addExternalEditFormCustom (ilPropertyFormGUI $a_form)
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction ($a_cmd, $a_formaction="")
 get form action for command (command is method name without "Object", e.g. More...
 
 isVisible ($a_ref_id, $a_type)
 
 viewObject ()
 viewObject container presentation for "administration -> repository, trash, permissions" More...
 
 deleteObject ($a_error=false)
 Display deletion confirmation screen. More...
 
 cloneAllObject ()
 Clone single (not container object) Method is overwritten in ilContainerGUI. More...
 
 redirectAfterCreation ()
 Redirect after creation, see https://docu.ilias.de/goto_docu_wiki_wpage_5035_1357.html. More...
 
 addToDeskObject ()
 @inheritDoc More...
 
 removeFromDeskObject ()
 @inheritDoc More...
 
- 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 ($ref_id)
 
- Static Public Member Functions inherited from ilContainerGUI
static _buildPath ($a_ref_id, $a_course_ref_id)
 build path More...
 
- Static Public Member Functions inherited from ilObjectGUI
static _gotoRepositoryRoot ($a_raise_error=false)
 Goto repository root. More...
 
static _gotoRepositoryNode ($a_ref_id, $a_cmd="frameset")
 Goto repository root. More...
 

Data Fields

const TAB_POSITIONS = 'positions'
 
const TAB_ORGU_TYPES = 'orgu_types'
 
const TAB_SETTINGS = "settings"
 
const TAB_STAFF = 'orgu_staff'
 
const TAB_GLOBAL_SETTINGS = 'global_settings'
 
const TAB_EXPORT = 'export'
 
const TAB_VIEW_CONTENT = 'view_content'
 
 $ctrl
 
 $tpl
 
 $tabs_gui
 
 $tree
 
 $object
 
 $ilias
 
const CMD_EDIT_SETTINGS = 'editSettings'
 
- Data Fields inherited from ilContainerGUI
 $bl_cnt = 1
 
 $multi_download_enabled = false
 
- Data Fields inherited from ilObjectGUI
const ALLOWED_TAGS_IN_TITLE_AND_DESCRIPTION
 
const COPY_WIZARD_NEEDS_PAGE = 1
 
 $objDefinition
 
 $tpl
 
 $tree
 
 $lng
 
 $data
 
 $object
 
 $ref_id
 
 $obj_id
 
 $maxcount
 
 $formaction
 
 $return_location
 
 $target_frame
 
 $tab_target_script
 
 $actions
 
 $sub_objects
 
 $omit_locator = false
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 

Protected Member Functions

 afterSave (ilObject $a_new_object)
 @inheritDoc More...
 
 initCreationForms ($a_new_type)
 initCreationForms More...
 
 addAdminLocatorItems ($a_do_not_add_object=false)
 
 redirectToRefId ($a_ref_id, $a_cmd="")
 
 setSubTabsSettings ($active_tab_id)
 
 initAdvancedSettingsForm ()
 Initialize the form for editing advanced meta data. More...
 
 editAdvancedSettings ()
 Edit Advanced Metadata. More...
 
 updateAdvancedSettings ()
 Update Advanced Metadata. More...
 
 getTreeSelectorGUI ($cmd)
 
- Protected Member Functions inherited from ilContainerGUI
 getEditFormValues ()
 Get values for edit form. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 supportsPageEditor ()
 
 showPasswordInstructionObject ($a_init=true)
 Show webdav password instruction. More...
 
 initFormPasswordInstruction ()
 Init password form. More...
 
 savePasswordObject ()
 Save password. More...
 
 initHeaderAction ($a_sub_type=null, $a_sub_id=null)
 Add file manager link. More...
 
 fileManagerLaunchObject ()
 Launch jnlp. More...
 
 initEditForm ()
 Init object edit form. More...
 
 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)
 Save list presentation setting. More...
 
 initSortingDirectionForm (ilContainerSortingSettings $sorting_settings, $element, $a_prefix)
 Add sorting direction. More...
 
 initManualSortingOptionForm (ilContainerSortingSettings $settings, $element, $a_prefix, $a_sorting_settings)
 Add manual sorting options. More...
 
 saveSortingSettings (ilPropertyFormGUI $form)
 Save sorting settings. More...
 
 trashHandleFilter (bool $action_apply, bool $action_reset)
 
 restoreToNewLocationObject (\ilPropertyFormGUI $form=null)
 
 getTreeSelectorGUI ($cmd)
 
 initFilter ()
 Init filter. More...
 
- Protected Member Functions inherited from ilObjectGUI
 getObjectService ()
 Get object service. More...
 
 assignObject ()
 
 setTitleAndDescription ()
 called by prepare output More...
 
 initHeaderAction ($a_sub_type=null, $a_sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction ($a_list_gui)
 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 @access public More...
 
 setAdminTabs ()
 set admin tabs @access public More...
 
 setLocator ()
 set Locator More...
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator ($a_omit=true)
 
 addAdminLocatorItems ($a_do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 initCreationForms ($a_new_type)
 Init creation froms. More...
 
 getCreationFormsHTML (array $a_forms)
 Get HTML for creation forms (accordion) More...
 
 initCreateForm ($a_new_type)
 Init object creation form. More...
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 Show didactic template types. More...
 
 addDidacticTemplateOptions (array &$a_options)
 Add custom templates. More...
 
 afterSave (ilObject $a_new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 Init object edit form. More...
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 Get values for edit form. More...
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $a_form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $a_form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 initImportForm ($a_new_type)
 Init object import form. More...
 
 importFileObject ($parent_id=null, $a_catch_errors=true)
 Import. More...
 
 afterImport (ilObject $a_new_object)
 Post (successful) object import hook. More...
 
 setFormAction ($a_cmd, $a_formaction)
 set specific form action for command More...
 
 getReturnLocation ($a_cmd, $a_location="")
 get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation ($a_cmd, $a_location)
 set specific return location for command More...
 
 getTargetFrame ($a_cmd, $a_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame ($a_cmd, $a_target_frame)
 set specific target frame for command More...
 
 showPossibleSubObjects ()
 show possible subobjects (pulldown menu) More...
 
 getTemplateFile ($a_cmd, $a_type="")
 get a template blockfile format: tpl. More...
 
 getTabs ()
 get tabs abstract method. More...
 
 __showButton ($a_cmd, $a_text, $a_target='')
 
 hitsperpageObject ()
 
__initTableGUI ()
 
 __setTableGUIBasicData (&$tbl, &$result_set, $a_from="")
 standard implementation for tables use 'from' variable use different initial setting of table More...
 
 redirectToRefId ($a_ref_id, $a_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 $_GET["ref_id"] value More...
 
 fillCloneTemplate ($a_tpl_varname, $a_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...
 
 setColumnSettings (ilColumnGUI $column_gui)
 May be overwritten in subclasses. More...
 
 checkPermission ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission and redirect on error. More...
 
 checkPermissionBool ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission. More...
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 handleAutoRating (ilObject $a_new_obj)
 Activate rating automatically if parent container setting. More...
 

Protected Attributes

 $ilAccess
 
 $toolbar
 
 $ilLocator
 
 $ilLog
 
- Protected Attributes inherited from ilContainerGUI
 $rbacsystem
 
 $tabs
 
 $settings
 
 $user
 
 $db
 
 $access
 
 $error
 
 $obj_definition
 
 $rbacadmin
 
 $rbacreview
 
 $log
 
 $obj_data_cache
 
 $toolbar
 
 $plugin_admin
 
 $global_screen
 
 $app_event_handler
 
 $ui
 
 $container_filter_service
 
 $container_user_filter = null
 
 $ui_filter
 
- Protected Attributes inherited from ilObjectGUI
const UPLOAD_TYPE_LOCAL = 1
 
const UPLOAD_TYPE_UPLOAD_DIRECTORY = 2
 
 $ilErr
 
 $locator
 
 $user
 
 $access
 
 $rbacsystem
 
 $settings
 
 $rbacreview
 
 $toolbar
 
 $tmp_import_dir
 
 $tabs_gui = null
 
 $ctrl
 
 $object_service
 
 $favourites
 
 $request
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilObjOrgUnitGUI::__construct ( )

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

81 {
82 global $DIC;
83 $tpl = $DIC['tpl'];
84 $ilCtrl = $DIC['ilCtrl'];
85 $ilAccess = $DIC['ilAccess'];
86 $ilToolbar = $DIC['ilToolbar'];
87 $ilLocator = $DIC['ilLocator'];
88 $tree = $DIC['tree'];
89 $lng = $DIC['lng'];
90 $ilLog = $DIC['ilLog'];
91 $ilias = $DIC['ilias'];
92 parent::__construct(array(), $_GET["ref_id"], true, false);
93
94 $this->tpl = $tpl;
95 $this->ctrl = $ilCtrl;
96 $this->ilAccess = $ilAccess;
97 $this->ilLocator = $ilLocator;
98 $this->tree = $tree;
99 $this->toolbar = $ilToolbar;
100 $this->ilLog = $ilLog;
101 $this->ilias = $ilias;
102 $this->type = 'orgu';
103
104 $lng->loadLanguageModule("orgu");
105 $this->tpl->addCss('./Modules/OrgUnit/templates/default/orgu.css');
106
107 $DIC->globalScreen()->tool()->context()->current()->addAdditionalData(OrgUnitToolProvider::SHOW_ORGU_TREE, true);
108 }
$_GET["client_id"]
Class ilAccessHandler.
logging
Definition: class.ilLog.php:19
global $DIC
Definition: goto.php:24
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
redirection script todo: (a better solution should control the processing via a xml file)

References $_GET, $DIC, $ilAccess, $ilias, $ilLocator, $ilLog, ilObjectGUI\$lng, $tpl, $tree, and ILIAS\GlobalScreen\Provider\__construct().

+ Here is the call graph for this function:

Member Function Documentation

◆ __initTableGUI()

& ilObjOrgUnitGUI::__initTableGUI ( )
Returns
ilTableGUI @description Make protected function avaiable for ilLocalUserGUI...

Reimplemented from ilObjectGUI.

Definition at line 738 of file class.ilObjOrgUnitGUI.php.

739 {
740 return parent::__initTableGUI();
741 }

◆ __setTableGUIBasicData()

ilObjOrgUnitGUI::__setTableGUIBasicData ( $tbl,
$result_set,
  $a_from = "" 
)
Returns
ilTableGUI @description Make protected function avaiable for ilLocalUserGUI...

Reimplemented from ilObjectGUI.

Definition at line 790 of file class.ilObjOrgUnitGUI.php.

791 {
792 return parent::__setTableGUIBasicData($tbl, $result_set, $a_from);
793 }

◆ _goto()

static ilObjOrgUnitGUI::_goto (   $ref_id)
static

Definition at line 673 of file class.ilObjOrgUnitGUI.php.

674 {
675 global $DIC;
676 $ilCtrl = $DIC['ilCtrl'];
677 $ilCtrl->initBaseClass("ilAdministrationGUI");
678 $ilCtrl->setParameterByClass("ilObjOrgUnitGUI", "ref_id", $ref_id);
679 $ilCtrl->setParameterByClass("ilObjOrgUnitGUI", "admin_mode", self::TAB_SETTINGS);
680 $ilCtrl->setParameterByClass("IlObjPluginDispatchGUI", "admin_mode", self::TAB_SETTINGS);
681 $ilCtrl->redirectByClass(array("ilAdministrationGUI", "ilObjOrgUnitGUI"), "view");
682 }

References $DIC, and ilObjectGUI\$ref_id.

◆ addAdminLocatorItems()

ilObjOrgUnitGUI::addAdminLocatorItems (   $a_do_not_add_object = false)
protected
Parameters
bool$a_do_not_add_object

Reimplemented from ilObjectGUI.

Definition at line 441 of file class.ilObjOrgUnitGUI.php.

442 {
443 $path = $this->tree->getPathFull($_GET["ref_id"], ilObjOrgUnit::getRootOrgRefId());
444 // add item for each node on path
445 foreach ((array) $path as $key => $row) {
446 if ($row["title"] == "__OrgUnitAdministration") {
447 $row["title"] = $this->lng->txt("objs_orgu");
448 }
449 $this->ctrl->setParameterByClass("ilobjorgunitgui", "ref_id", $row["child"]);
450 $this->ilLocator->addItem($row["title"], $this->ctrl->getLinkTargetByClass("ilobjorgunitgui", "view"), ilFrameTargetInfo::_getFrame("MainContent"), $row["child"]);
451 $this->ctrl->setParameterByClass("ilobjorgunitgui", "ref_id", $_GET["ref_id"]);
452 }
453 }
static _getFrame($a_class, $a_type='')
Get content frame name.
static getRootOrgRefId()

References $_GET, ilFrameTargetInfo\_getFrame(), and ilObjOrgUnit\getRootOrgRefId().

+ Here is the call graph for this function:

◆ afterSave()

ilObjOrgUnitGUI::afterSave ( ilObject  $a_new_object)
protected

@inheritDoc

Reimplemented from ilObjectGUI.

Definition at line 358 of file class.ilObjOrgUnitGUI.php.

359 {
360 ilUtil::sendSuccess($this->lng->txt("object_added"), true);
361 $this->ctrl->setParameter($this, "ref_id", $a_new_object->getRefId());
362 ilUtil::redirect($this->getReturnLocation("save", $this->ctrl->getLinkTarget($this, self::CMD_EDIT_SETTINGS, "", false, false)));
363 }
getReturnLocation($a_cmd, $a_location="")
get return location for command (command is method name without "Object", e.g.
getRefId()
get reference id @access public
static redirect($a_script)

References ilObject\getRefId(), ilObjectGUI\getReturnLocation(), and ilUtil\redirect().

+ Here is the call graph for this function:

◆ cancelMoveLinkObject()

ilObjOrgUnitGUI::cancelMoveLinkObject ( )

Cancel move|link empty clipboard and return to parent.

Reimplemented from ilContainerGUI.

Definition at line 796 of file class.ilObjOrgUnitGUI.php.

797 {
798 global $DIC;
799 $parent_ref_id = $_SESSION["clipboard"]["parent"];
800 unset($_SESSION['clipboard']);
801 $DIC->ctrl()->setParameter($this, 'ref_id', $parent_ref_id);
802 $DIC->ctrl()->redirect($this);
803 }
$_SESSION["AccountId"]

References $_SESSION, and $DIC.

Referenced by executeCommand().

+ Here is the caller graph for this function:

◆ confirmedDeleteObject()

ilObjOrgUnitGUI::confirmedDeleteObject ( )

confirmed deletion of org units -> org units are deleted immediately, without putting them to the trash

Exceptions
ilRepositoryException

Reimplemented from ilObjectGUI.

Definition at line 747 of file class.ilObjOrgUnitGUI.php.

748 {
749 global $DIC;
750
751 $ids = filter_input(INPUT_POST, 'id', FILTER_DEFAULT, FILTER_REQUIRE_ARRAY);
752 if (count($ids) > 0) {
754 ilUtil::sendSuccess($DIC->language()->txt("info_deleted"), true);
755 }
756 $this->ctrl->returnToParent($this);
757 }
static removeObjectsFromSystem($a_ref_ids, $a_from_recovery_folder=false)
remove objects from trash bin and all entries therefore every object needs a specific deleteObject() ...

References $DIC, and ilRepUtil\removeObjectsFromSystem().

Referenced by executeCommand().

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

◆ deleteObject()

ilObjOrgUnitGUI::deleteObject (   $a_error = false)

Display deletion confirmation screen for Org Units.

Information to the user that Org units will be deleted immediately.

@access public

Reimplemented from ilObjectGUI.

Definition at line 766 of file class.ilObjOrgUnitGUI.php.

767 {
768 $ilCtrl = $this->ctrl;
769 require_once("./Services/Repository/classes/class.ilRepUtilGUI.php");
770 $ru = new ilRepUtilGUI($this);
771
772 $arr_ref_ids = [];
773 //Delete via Manage (more than one)
774 if (is_array($_POST['id']) && count($_POST['id']) > 0) {
775 $arr_ref_ids = $_POST['id'];
776 } elseif ($_GET['item_ref_id'] > 0) {
777 $arr_ref_ids = [$_GET['item_ref_id']];
778 }
779
780 if (!$ru->showDeleteConfirmation($arr_ref_ids, false)) {
781 $ilCtrl->returnToParent($this);
782 }
783 }
$_POST["username"]
Repository GUI Utilities.

References $_GET, $_POST, and $ctrl.

Referenced by executeCommand().

+ Here is the caller graph for this function:

◆ doUserAutoCompleteObject()

ilObjOrgUnitGUI::doUserAutoCompleteObject ( )

??

Definition at line 727 of file class.ilObjOrgUnitGUI.php.

728 {
729 }

◆ editAdvancedSettings()

ilObjOrgUnitGUI::editAdvancedSettings ( )
protected

Edit Advanced Metadata.

Definition at line 584 of file class.ilObjOrgUnitGUI.php.

585 {
586 if (!$this->ilAccess->checkAccess("write", "", $this->ref_id)) {
587 ilUtil::sendFailure($this->lng->txt("permission_denied"), true);
588 $this->ctrl->redirect($this);
589 }
590 $form = $this->initAdvancedSettingsForm();
591 $gui = new ilAdvancedMDRecordGUI(ilAdvancedMDRecordGUI::MODE_EDITOR, 'orgu', $this->object->getId(), 'orgu_type', $this->object->getOrgUnitTypeId());
592 $gui->setPropertyForm($form);
593 $gui->parse();
594 $this->tpl->setContent($form->getHTML());
595 }
checkAccess($a_permission, $a_cmd, $a_ref_id, $a_type="", $a_obj_id="", $a_tree_id="")
check access for an object (provide $a_type and $a_obj_id if available for better performance)
initAdvancedSettingsForm()
Initialize the form for editing advanced meta data.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.

References ilAccess\checkAccess(), initAdvancedSettingsForm(), ilAdvancedMDRecordGUI\MODE_EDITOR, and ilUtil\sendFailure().

Referenced by executeCommand().

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

◆ editSettings()

ilObjOrgUnitGUI::editSettings ( )

Definition at line 622 of file class.ilObjOrgUnitGUI.php.

623 {
624 if (!$this->ilAccess->checkAccess("write", "", $this->ref_id)) {
625 ilUtil::sendFailure($this->lng->txt("permission_denied"), true);
626 $this->ctrl->redirect($this);
627 }
628 $form = new ilObjOrgUnitSettingsFormGUI($this, $this->object);
629 $this->tpl->setContent($form->getHTML());
630 }
Class ilObjOrgUnitSettingsFormGUI.

References ilAccess\checkAccess(), and ilUtil\sendFailure().

Referenced by executeCommand().

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

◆ executeCommand()

ilObjOrgUnitGUI::executeCommand ( )
Exceptions
ilCtrlException
ilException
ilRepositoryException

Reimplemented from ilContainerGUI.

Definition at line 115 of file class.ilObjOrgUnitGUI.php.

116 {
117 $cmd = $this->ctrl->getCmd();
118 $next_class = $this->ctrl->getNextClass($this);
119 parent::prepareOutput();
120
121 switch ($next_class) {
122 case 'ilorgunitglobalsettingsgui':
123 $this->tabs_gui->activateTab(self::TAB_GLOBAL_SETTINGS);
124 $global_settings = new ilOrgUnitGlobalSettingsGUI();
125 $this->ctrl->forwardCommand($global_settings);
126 break;
127 case "illocalusergui":
129 ilUtil::sendFailure($this->lng->txt("permission_denied"), true);
130 $this->ctrl->redirect($this);
131 }
132 $this->tabs_gui->activateTab('administrate_users');
133 $ilLocalUserGUI = new ilLocalUserGUI($this);
134 $this->ctrl->forwardCommand($ilLocalUserGUI);
135 break;
136 case "ilorgunitsimpleimportgui":
137 $this->tabs_gui->activateTab("view");
138 $this->setContentSubTabs();
139 $this->tabs_gui->setSubTabActive('import');
140 $ilOrgUnitSimpleImportGUI = new ilOrgUnitSimpleImportGUI($this);
141 $this->ctrl->forwardCommand($ilOrgUnitSimpleImportGUI);
142 break;
143 case "ilorgunitsimpleuserimportgui":
144 $ilOrgUnitSimpleUserImportGUI = new ilOrgUnitSimpleUserImportGUI($this);
145 $this->ctrl->forwardCommand($ilOrgUnitSimpleUserImportGUI);
146 break;
147 case "ilorgunitstaffgui":
148 case "ilrepositorysearchgui":
149 $this->tabs_gui->activateTab(self::TAB_STAFF);
150 $ilOrgUnitStaffGUI = new ilOrgUnitStaffGUI($this);
151 $this->ctrl->forwardCommand($ilOrgUnitStaffGUI);
152 break;
153 case "ilobjusergui":
154 switch ($cmd) {
155 case "create":
156 $ilObjUserGUI = new ilObjUserGUI("", (int) $_GET['ref_id'], true, false);
157 $ilObjUserGUI->setCreationMode(true);
158 $this->ctrl->forwardCommand($ilObjUserGUI);
159 $this->tabs_gui->setBackTarget($this->lng->txt("back"), $this->ctrl->getLinkTargetByClass("illocalusergui", 'index'));
160 break;
161 case "save":
162 $ilObjUserGUI = new ilObjUserGUI("", $_GET['ref_id'], true, false);
163 $ilObjUserGUI->setCreationMode(true);
164 $this->ctrl->forwardCommand($ilObjUserGUI);
165 $this->tabs_gui->clearTargets();
166 $this->tabs_gui->setBackTarget($this->lng->txt("back"), $this->ctrl->getLinkTargetByClass("illocalusergui", 'index'));
167 break;
168 case "view":
169 case "update":
170 $ilObjUserGUI = new ilObjUserGUI("", (int) $_GET['obj_id'], false, false);
171 $ilObjUserGUI->setCreationMode(false);
172 $this->ctrl->forwardCommand($ilObjUserGUI);
173 $this->tabs_gui->clearTargets();
174 $this->tabs_gui->setBackTarget($this->lng->txt("back"), $this->ctrl->getLinkTargetByClass("illocalusergui", 'index'));
175 break;
176 case "cancel":
177 $this->ctrl->redirectByClass("illocalusergui", "index");
178 break;
179 }
180 break;
181 case "ilobjuserfoldergui":
182 switch ($cmd) {
183 case "view":
184 $this->ctrl->redirectByClass("illocalusergui", "index");
185 break;
186 default:
187 $ilObjUserFolderGUI = new ilObjUserFolderGUI("", (int) $_GET['ref_id'], true, false);
188 $ilObjUserFolderGUI->setUserOwnerId((int) $_GET['ref_id']);
189 $ilObjUserFolderGUI->setCreationMode(true);
190 $this->ctrl->forwardCommand($ilObjUserFolderGUI);
191 $this->tabs_gui->clearTargets();
192 $this->tabs_gui->setBackTarget($this->lng->txt("back"), $this->ctrl->getLinkTargetByClass("illocalusergui", 'index'));
193 break;
194 }
195 break;
196 case "ilinfoscreengui":
197 $this->tabs_gui->activateTab("info_short");
198 if (!$this->ilAccess->checkAccess("read", "", $this->ref_id) and !$this->ilAccess->checkAccess("visible", "", $this->ref_id)) {
199 $this->ilias->raiseError($this->lng->txt("msg_no_perm_read"), $this->ilias->error_obj->MESSAGE);
200 }
201 $info = new ilInfoScreenGUI($this);
202 $amd_gui = new ilAdvancedMDRecordGUI(ilAdvancedMDRecordGUI::MODE_INFO, 'orgu', $this->object->getId(), 'orgu_type', $this->object->getOrgUnitTypeId());
203 $amd_gui->setInfoObject($info);
204 $amd_gui->parse();
205 $this->ctrl->forwardCommand($info);
206 break;
207 case 'ilpermissiongui':
208 $this->tabs_gui->activateTab('perm_settings');
209 $ilPermissionGUI = new ilPermissionGUI($this);
210 $this->ctrl->forwardCommand($ilPermissionGUI);
211 break;
212 case "ilcommonactiondispatchergui":
214 $this->ctrl->forwardCommand($gui);
215 break;
216 case 'illearningprogressgui':
217 case 'illplistofprogressgui':
218 $this->tabs_gui->clearTargets();
219 $this->tabs_gui->setBackTarget($this->lng->txt('backto_staff'), $this->ctrl->getLinkTargetByClass(ilOrgUnitUserAssignmentGUI::class, ilOrgUnitUserAssignmentGUI::CMD_INDEX));
220 if (!ilObjOrgUnitAccess::_checkAccessToUserLearningProgress($this->object->getRefid(), $_GET['obj_id'])) {
221 ilUtil::sendFailure($this->lng->txt("permission_denied"), true);
222 $this->ctrl->redirectByClass("ilOrgUnitStaffGUI", "showStaff");
223 }
224 $this->ctrl->saveParameterByClass("illearningprogressgui", "obj_id");
225 $this->ctrl->saveParameterByClass("illearningprogressgui", "recursive");
227 $this->ctrl->forwardCommand($new_gui);
228 break;
229 case 'ilorgunitexportgui':
230 if (!ilObjOrgUnitAccess::_checkAccessExport((int) $_GET['ref_id'])) {
231 ilUtil::sendFailure($this->lng->txt("permission_denied"), true);
232 $this->ctrl->redirect($this);
233 }
234 $this->tabs_gui->activateTab(self::TAB_EXPORT);;
235 $ilOrgUnitExportGUI = new ilOrgUnitExportGUI($this);
236 $ilOrgUnitExportGUI->addFormat('xml');
237 $this->ctrl->forwardCommand($ilOrgUnitExportGUI);
238 break;
239 case strtolower(ilTranslationGUI::class):
240 $this->tabs_gui->activateTab(self::TAB_SETTINGS);
241 $this->setSubTabsSettings('edit_translations');
242 $ilTranslationGui = new ilTranslationGUI($this);
243 $this->ctrl->forwardCommand($ilTranslationGui);
244 break;
245 case strtolower(ilOrgUnitTypeGUI::class):
246 $this->tabs_gui->activateTab(self::TAB_ORGU_TYPES);
247 $types_gui = new ilOrgUnitTypeGUI($this);
248 $this->ctrl->forwardCommand($types_gui);
249 break;
250 case strtolower(ilOrgUnitPositionGUI::class):
251 $this->tabs_gui->activateTab(self::TAB_POSITIONS);
252 $types_gui = new ilOrgUnitPositionGUI($this);
253 $this->ctrl->forwardCommand($types_gui);
254 break;
255 case strtolower(ilOrgUnitUserAssignmentGUI::class):
256 $this->tabs_gui->activateTab(self::TAB_STAFF);
257 $ilOrgUnitUserAssignmentGUI = new ilOrgUnitUserAssignmentGUI();
258 $this->ctrl->forwardCommand($ilOrgUnitUserAssignmentGUI);
259 break;
260 case strtolower(ilPropertyFormGUI::class):
261 /*
262 * Only used for async loading of the repository tree in custom md
263 * internal links (see #24875). This is necessary since OrgUnits don't
264 * use ilObjectMetaDataGUI.
265 */
266 $form = $this->initAdvancedSettingsForm();
267 $gui = new ilAdvancedMDRecordGUI(ilAdvancedMDRecordGUI::MODE_EDITOR, 'orgu', $this->object->getId(), 'orgu_type', $this->object->getOrgUnitTypeId());
268 $gui->setPropertyForm($form);
269 $gui->parse();
270 $this->ctrl->forwardCommand($form);
271 break;
272 default:
273 $this->tabs_gui->activateTab(self::TAB_VIEW_CONTENT);
274 switch ($cmd) {
275 case '':
276 case 'view':
277 case 'render':
278 case 'cancel':
279 case 'cancelDelete':
280 $this->view();
281 break;
282 case 'performPaste':
283 case 'paste':
284 $this->performPaste();
285 break;
286 case 'performPasteIntoMultipleObjects':
288 break;
289 case 'keepObjectsInClipboard':
291 break;
292 case 'create':
293 parent::createObject();
294 break;
295 case 'save':
296 parent::saveObject();
297 break;
298 case 'delete':
299 $this->tabs_gui->clearTargets();
300 $this->tabs_gui->setBackTarget($this->lng->txt("back"), $this->ctrl->getLinkTarget($this));
301 $this->deleteObject();
302 break;
303 case 'confirmedDelete':
304 $this->confirmedDeleteObject();
305 break;
306 case 'cut':
307 $this->tabs_gui->clearTargets();
308 $this->tabs_gui->setBackTarget($this->lng->txt("back"), $this->ctrl->getLinkTarget($this));
309 parent::cutObject();
310 break;
311 case 'clear':
312 parent::clearObject();
313 break;
314 case 'enableAdministrationPanel':
315 parent::enableAdministrationPanelObject();
316 break;
317 case 'disableAdministrationPanel':
318 parent::disableAdministrationPanelObject();
319 break;
320 case 'getAsynchItemList':
321 parent::getAsynchItemListObject();
322 break;
324 $this->tabs_gui->activateTab(self::TAB_SETTINGS);
325 $this->setSubTabsSettings('edit_settings');
326 $this->editSettings();
327 break;
328 case 'updateSettings':
329 $this->tabs_gui->activateTab(self::TAB_SETTINGS);
330 $this->setSubTabsSettings('edit_settings');
331 $this->updateSettings();
332 break;
333 case 'editAdvancedSettings':
334 $this->tabs_gui->activateTab(self::TAB_SETTINGS);
335 $this->setSubTabsSettings('edit_advanced_settings');
336 $this->editAdvancedSettings();
337 break;
338 case 'updateAdvancedSettings':
339 $this->tabs_gui->activateTab(self::TAB_SETTINGS);
340 $this->setSubTabsSettings('edit_advanced_settings');
341 $this->updateAdvancedSettings();
342 break;
343 case 'importFile':
344 $this->importFileObject();
345 break;
346 case 'cancelMoveLink':
347 $this->cancelMoveLinkObject();
348 break;
349 }
350 break;
351 }
352 }
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
keepObjectsInClipboardObject()
Keep objects in the clipboard.
Class ilInfoScreenGUI.
Class ilObjUserTrackingGUI.
Class ilLocalUserGUI.
static _checkAccessToUserLearningProgress($ref_id, $usr_id)
static _checkAccessExport(int $ref_id)
static _checkAccessAdministrateUsers($ref_id)
confirmedDeleteObject()
confirmed deletion of org units -> org units are deleted immediately, without putting them to the tra...
updateAdvancedSettings()
Update Advanced Metadata.
setContentSubTabs()
Set content sub tabs.
editAdvancedSettings()
Edit Advanced Metadata.
cancelMoveLinkObject()
Cancel move|link empty clipboard and return to parent.
performPaste()
@description Prepare $_POST for the generic method performPasteIntoMultipleObjectsObject
setSubTabsSettings($active_tab_id)
deleteObject($a_error=false)
Display deletion confirmation screen for Org Units.
Class ilObjUserFolderGUI.
Class ilObjUserGUI.
importFileObject($parent_id=null, $a_catch_errors=true)
Import.
Class ilOrgUnitExportGUI.
Class ilOrgUnitPositionGUI.
Class ilOrgUnitSimpleImportGUI.
Class ilOrgUnitSimpleUserImportGUI.
Class ilOrgUnitStaffGUI.
Class ilOrgUnitTypeGUI.
Class ilOrgUnitUserAssignmentGUI.
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
Class ilTranslationGUI.

References $_GET, ilObjOrgUnitAccess\_checkAccessAdministrateUsers(), ilObjOrgUnitAccess\_checkAccessExport(), ilObjOrgUnitAccess\_checkAccessToUserLearningProgress(), cancelMoveLinkObject(), ilAccess\checkAccess(), CMD_EDIT_SETTINGS, ILIAS\Modules\OrgUnit\ARHelper\BaseCommands\CMD_INDEX, confirmedDeleteObject(), deleteObject(), editAdvancedSettings(), editSettings(), ilCommonActionDispatcherGUI\getInstanceFromAjaxCall(), ilObjectGUI\importFileObject(), initAdvancedSettingsForm(), ilContainerGUI\keepObjectsInClipboardObject(), ilLearningProgressBaseGUI\LP_CONTEXT_ORG_UNIT, ilAdvancedMDRecordGUI\MODE_EDITOR, ilAdvancedMDRecordGUI\MODE_INFO, performPaste(), ilContainerGUI\performPasteIntoMultipleObjectsObject(), ilUtil\sendFailure(), setContentSubTabs(), setSubTabsSettings(), updateAdvancedSettings(), updateSettings(), and view().

+ Here is the call graph for this function:

◆ getAdminTabs()

ilObjOrgUnitGUI::getAdminTabs ( )
Parameters
ilTabsGUI$tabs_gui

Reimplemented from ilContainerGUI.

Definition at line 700 of file class.ilObjOrgUnitGUI.php.

701 {
702 $this->getTabs();
703 }

References getTabs().

+ Here is the call graph for this function:

◆ getTabs()

ilObjOrgUnitGUI::getTabs ( )
Parameters
ilTabsGUI$tabs_gui

Reimplemented from ilContainerGUI.

Definition at line 475 of file class.ilObjOrgUnitGUI.php.

476 {
477 $read_access_ref_id = $this->rbacsystem->checkAccess('visible,read', $this->object->getRefId());
478 if ($read_access_ref_id) {
479 $this->tabs_gui->addTab(self::TAB_VIEW_CONTENT, $this->lng->txt("content"), $this->ctrl->getLinkTarget($this, ""));
480 $this->tabs_gui->addTab("info_short", "Info", $this->ctrl->getLinkTargetByClass("ilinfoscreengui", "showSummary"));
481 }
482
483 // Tabs for OrgUnits exclusive root!
484 if ($this->object->getRefId() != ilObjOrgUnit::getRootOrgRefId()) {
485 if (ilObjOrgUnitAccess::_checkAccessStaff($this->object->getRefId())) {
486 // $this->tabs_gui->addTab('legacy_staff', 'legacy_staff', $this->ctrl->getLinkTargetByClass("ilOrgUnitStaffGUI", "showStaff"));
487 $this->tabs_gui->addTab(self::TAB_STAFF, $this->lng->txt(self::TAB_STAFF), $this->ctrl->getLinkTargetByClass(ilOrgUnitUserAssignmentGUI::class, ilOrgUnitUserAssignmentGUI::CMD_INDEX));
488 }
489 if (ilObjOrgUnitAccess::_checkAccessSettings($this->object->getRefId())) {
490 $this->tabs_gui->addTab(self::TAB_SETTINGS, $this->lng->txt(self::TAB_SETTINGS), $this->ctrl->getLinkTarget($this, self::CMD_EDIT_SETTINGS));
491 }
492 if (ilObjOrgUnitAccess::_checkAccessAdministrateUsers($this->object->getRefId())) {
493 $this->tabs_gui->addTab("administrate_users", $this->lng->txt("administrate_users"), $this->ctrl->getLinkTargetByClass("ilLocalUserGUI", "index"));
494 }
495 }
496
497 if (ilObjOrgUnitAccess::_checkAccessSettings($this->object->getRefId())) {
498 if ($this->object->getRefId() == ilObjOrgUnit::getRootOrgRefId()) {
499 $this->tabs_gui->addTab(self::TAB_GLOBAL_SETTINGS, $this->lng->txt('settings'), $this->ctrl->getLinkTargetByClass(ilOrgUnitGlobalSettingsGUI::class));
500 }
501 $this->tabs_gui->addTab(self::TAB_EXPORT, $this->lng->txt(self::TAB_EXPORT), $this->ctrl->getLinkTargetByClass(ilOrgUnitExportGUI::class));
502
503 // Add OrgUnit types and positions tabs
504 if ($this->object->getRefId() == ilObjOrgUnit::getRootOrgRefId()) {
505 $this->tabs_gui->addTab(self::TAB_ORGU_TYPES, $this->lng->txt(self::TAB_ORGU_TYPES), $this->ctrl->getLinkTargetByClass(ilOrgUnitTypeGUI::class));
506 $this->tabs_gui->addTab(self::TAB_POSITIONS, $this->lng->txt(self::TAB_POSITIONS), $this->ctrl->getLinkTargetByClass(ilOrgUnitPositionGUI::class));
507 }
508 }
509 parent::getTabs();
510 }
static _checkAccessStaff($ref_id)
static _checkAccessSettings(int $ref_id)

References ilObjOrgUnitAccess\_checkAccessAdministrateUsers(), ilObjOrgUnitAccess\_checkAccessSettings(), ilObjOrgUnitAccess\_checkAccessStaff(), ILIAS\Modules\OrgUnit\ARHelper\BaseCommands\CMD_INDEX, and ilObjOrgUnit\getRootOrgRefId().

Referenced by getAdminTabs().

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

◆ getTreeSelectorGUI()

ilObjOrgUnitGUI::getTreeSelectorGUI (   $cmd)
protected
Parameters
$cmdstring
Returns
ilTreeExplorerGUI

Reimplemented from ilContainerGUI.

Definition at line 685 of file class.ilObjOrgUnitGUI.php.

686 {
687 global $DIC;
688 $tree = $DIC['tree'];
689 $explorer = new ilOrgUnitExplorerGUI("rep_exp_sel", $this, "showPasteTree", $tree);
690 $explorer->setAjax(false);
691 $explorer->setSelectMode('nodes[]', false);
692
693 return $explorer;
694 }
Class ilOrgUnitExplorerGUI.

References $DIC, and $tree.

◆ initAdvancedSettingsForm()

ilObjOrgUnitGUI::initAdvancedSettingsForm ( )
protected

Initialize the form for editing advanced meta data.

Returns
ilPropertyFormGUI

Definition at line 570 of file class.ilObjOrgUnitGUI.php.

571 {
572 $form = new ilPropertyFormGUI();
573 $form->setFormAction($this->ctrl->getFormAction($this));
574 $form->addCommandButton('updateAdvancedSettings', $this->lng->txt('save'));
575 $form->addCommandButton(self::CMD_EDIT_SETTINGS, $this->lng->txt('cancel'));
576
577 return $form;
578 }
This class represents a property form user interface.

Referenced by editAdvancedSettings(), executeCommand(), and updateAdvancedSettings().

+ Here is the caller graph for this function:

◆ initCreationForms()

ilObjOrgUnitGUI::initCreationForms (   $a_new_type)
protected

initCreationForms

We override the method of class.ilObjectGUI because we have no copy functionality at the moment

Parameters
string$a_new_type
Returns
array

Reimplemented from ilObjectGUI.

Definition at line 394 of file class.ilObjOrgUnitGUI.php.

395 {
396 $forms = array(
397 self::CFORM_NEW => $this->initCreateForm($a_new_type),
398 self::CFORM_IMPORT => $this->initImportForm($a_new_type),
399 );
400
401 return $forms;
402 }
initImportForm($a_new_type)
Init object import form.
initCreateForm($a_new_type)
Init object creation form.

References ilObjectGUI\initCreateForm(), and ilObjectGUI\initImportForm().

+ Here is the call graph for this function:

◆ performPaste()

ilObjOrgUnitGUI::performPaste ( )

@description Prepare $_POST for the generic method performPasteIntoMultipleObjectsObject

Definition at line 709 of file class.ilObjOrgUnitGUI.php.

710 {
711 if (!in_array($_SESSION['clipboard']['cmd'], array('cut'))) {
712 $message = __METHOD__ . ": cmd was not 'cut' ; may be a hack attempt!";
713 $this->ilias->raiseError($message, $this->ilias->error_obj->WARNING);
714 }
715 if ($_SESSION['clipboard']['cmd'] == 'cut') {
716 if (isset($_GET['ref_id']) && (int) $_GET['ref_id']) {
717 $this->pasteObject();
718 }
719 }
720 $this->ctrl->returnToParent($this);
721 }
pasteObject()
paste object from clipboard to current place Depending on the chosen command the object(s) are linked...
$message
Definition: xapiexit.php:14

References $_GET, $_SESSION, $message, and ilContainerGUI\pasteObject().

Referenced by executeCommand().

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

◆ redirectToRefId()

ilObjOrgUnitGUI::redirectToRefId (   $a_ref_id,
  $a_cmd = "" 
)
protected
Parameters
int$a_ref_id
string$a_cmd

Reimplemented from ilObjectGUI.

Definition at line 460 of file class.ilObjOrgUnitGUI.php.

461 {
462 $obj_type = ilObject::_lookupType($a_ref_id, true);
463 if ($obj_type != "orgu") {
464 parent::redirectToRefId($a_ref_id, $a_cmd);
465 } else {
466 $this->ctrl->setParameterByClass("ilObjOrgUnitGUI", "ref_id", $a_ref_id);
467 $this->ctrl->redirectByClass("ilObjOrgUnitGUI", $a_cmd);
468 }
469 }
static _lookupType($a_id, $a_reference=false)
lookup object type

References ilObject\_lookupType().

+ Here is the call graph for this function:

◆ setContentSubTabs()

ilObjOrgUnitGUI::setContentSubTabs ( )

Set content sub tabs.

Reimplemented from ilContainerGUI.

Definition at line 555 of file class.ilObjOrgUnitGUI.php.

556 {
558 //only display the import tab at the first level
559 if ($this->rbacsystem->checkAccess("create_orgu", $_GET["ref_id"]) and $this->object->getRefId() == ilObjOrgUnit::getRootOrgRefId()) {
560 $this->tabs_gui->addSubTab("import", $this->lng->txt("import"), $this->ctrl->getLinkTargetByClass("ilOrgUnitSimpleImportGUI", "chooseImport"));
561 }
562 }
addStandardContainerSubTabs($a_include_view=true)
Add standar container subtabs for view, manage, oderdering and text/media editor link.

References $_GET, ilContainerGUI\addStandardContainerSubTabs(), and ilObjOrgUnit\getRootOrgRefId().

Referenced by executeCommand().

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

◆ setSubTabsSettings()

ilObjOrgUnitGUI::setSubTabsSettings (   $active_tab_id)
protected
Parameters
$active_tab_id

Definition at line 516 of file class.ilObjOrgUnitGUI.php.

517 {
518 $next_class = $this->ctrl->getNextClass($this);
519 $cmd = $this->ctrl->getCmd();
520 $this->tabs_gui->addSubTab('edit_settings', $this->lng->txt(self::TAB_SETTINGS), $this->ctrl->getLinkTarget($this, self::CMD_EDIT_SETTINGS));
521 $this->tabs_gui->addSubTab("edit_translations", $this->lng->txt("obj_multilinguality"), $this->ctrl->getLinkTargetByClass("iltranslationgui", "editTranslations"));
522
523 $ilOrgUnitType = $this->object->getOrgUnitType();
524 if ($ilOrgUnitType instanceof ilOrgUnitType) {
525 if (count($ilOrgUnitType->getAssignedAdvancedMDRecords(true))) {
526 $this->tabs_gui->addSubTab('edit_advanced_settings', $this->lng->txt('orgu_adv_settings'), $this->ctrl->getLinkTarget($this, 'editAdvancedSettings'));
527 }
528 }
529
530 $this->tabs_gui->setSubTabActive($active_tab_id);
531 switch ($next_class) {
532 case 'iltranslationgui':
533 $this->tabs_gui->setSubTabActive("edit_translations");
534 break;
535 case '':
536 switch ($cmd) {
538 $this->tabs_gui->setSubTabActive('edit_settings');
539 break;
540 case 'editAdvancedSettings':
541 case 'updateAdvancedSettings':
542 $this->tabs_gui->setSubTabActive('edit_advanced_settings');
543 break;
544 }
545 break;
546 }
547
548 return;
549 }
Class ilOrgUnitType.

References CMD_EDIT_SETTINGS.

Referenced by executeCommand().

+ Here is the caller graph for this function:

◆ setTitleAndDescription()

ilObjOrgUnitGUI::setTitleAndDescription ( )

called by prepare output

Reimplemented from ilContainerGUI.

Definition at line 418 of file class.ilObjOrgUnitGUI.php.

419 {
420 # all possible create permissions
421 parent::setTitleAndDescription();
422 if ($this->object->getTitle() == "__OrgUnitAdministration") {
423 $this->tpl->setTitle($this->lng->txt("objs_orgu"));
424 $this->tpl->setDescription($this->lng->txt("objs_orgu"));
425 }
426
427 // Check for custom icon of type
428 if ($this->ilias->getSetting('custom_icons')) {
429 $icons_cache = ilObjOrgUnit::getIconsCache();
430 $icon_file = (isset($icons_cache[$this->object->getId()])) ? $icons_cache[$this->object->getId()] : '';
431 if ($icon_file) {
432 $this->tpl->setTitleIcon($icon_file, $this->lng->txt("obj_" . $this->object->getType()));
433 }
434 }
435 }

◆ showPossibleSubObjects()

ilObjOrgUnitGUI::showPossibleSubObjects ( )

show possible sub objects selection list

Reimplemented from ilContainerGUI.

Definition at line 405 of file class.ilObjOrgUnitGUI.php.

406 {
407 $gui = new ilObjectAddNewItemGUI($this->object->getRefId());
409 //$gui->setCreationUrl("ilias.php?ref_id=" . $_GET["ref_id"] . "&admin_mode=settings&cmd=create&baseClass=ilAdministrationGUI&cmdClass=ilobjorgunitgui");
410 $gui->setCreationUrl($this->ctrl->getLinkTarget($this, 'create'));
411 $gui->render();
412 }
Render add new item selector.

References ilObjectDefinition\MODE_ADMINISTRATION.

◆ updateAdvancedSettings()

ilObjOrgUnitGUI::updateAdvancedSettings ( )
protected

Update Advanced Metadata.

Definition at line 601 of file class.ilObjOrgUnitGUI.php.

602 {
603 if (!$this->ilAccess->checkAccess("write", "", $this->ref_id)) {
604 ilUtil::sendFailure($this->lng->txt("permission_denied"), true);
605 $this->ctrl->redirect($this);
606 }
607 $form = $this->initAdvancedSettingsForm();
608 $gui = new ilAdvancedMDRecordGUI(ilAdvancedMDRecordGUI::MODE_EDITOR, 'orgu', $this->object->getId(), 'orgu_type', $this->object->getOrgUnitTypeId());
609 $gui->setPropertyForm($form);
610 $form->checkInput();
611 $gui->parse();
612 if ($gui->importEditFormPostValues()) {
613 $gui->writeEditForm();
614 ilUtil::sendSuccess($this->lng->txt('settings_saved'), true);
615 $this->ctrl->redirect($this, 'editAdvancedSettings');
616 } else {
617 $this->tpl->setContent($form->getHTML());
618 }
619 }

References ilAccess\checkAccess(), initAdvancedSettingsForm(), ilAdvancedMDRecordGUI\MODE_EDITOR, and ilUtil\sendFailure().

Referenced by executeCommand().

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

◆ updateSettings()

ilObjOrgUnitGUI::updateSettings ( )

Definition at line 633 of file class.ilObjOrgUnitGUI.php.

634 {
635 if (!$this->ilAccess->checkAccess("write", "", $this->ref_id)) {
636 ilUtil::sendFailure($this->lng->txt("permission_denied"), true);
637 $this->ctrl->redirect($this);
638 }
639 $form = new ilObjOrgUnitSettingsFormGUI($this, $this->object);
640 if ($form->saveObject()) {
641 ilUtil::sendSuccess($this->lng->txt('msg_obj_modified'), true);
642 $this->ctrl->redirect($this, self::CMD_EDIT_SETTINGS);
643 } else {
644 $this->tpl->setContent($form->getHTML());
645 }
646 }

References ilAccess\checkAccess(), and ilUtil\sendFailure().

Referenced by executeCommand().

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

◆ view()

ilObjOrgUnitGUI::view ( )

Definition at line 366 of file class.ilObjOrgUnitGUI.php.

367 {
368 if (!$this->rbacsystem->checkAccess("read", $_GET["ref_id"])) {
369 if ($this->rbacsystem->checkAccess("visible", $_GET["ref_id"])) {
370 ilUtil::sendFailure($this->lng->txt("msg_no_perm_read"));
371 $this->ctrl->redirectByClass('ilinfoscreengui', '');
372 }
373
374 $this->ilias->raiseError($this->lng->txt("msg_no_perm_read"), $this->ilias->error_obj->WARNING);
375 }
376
377 parent::renderObject();
378 $this->tabs_gui->activateTab(self::TAB_VIEW_CONTENT);
379 $this->tabs_gui->removeSubTab("page_editor");
380 $this->tabs_gui->removeSubTab("ordering"); // Mantis 0014728
381 }

References $_GET, and ilUtil\sendFailure().

Referenced by executeCommand().

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

Field Documentation

◆ $ctrl

ilObjOrgUnitGUI::$ctrl

Definition at line 40 of file class.ilObjOrgUnitGUI.php.

Referenced by deleteObject().

◆ $ilAccess

ilObjOrgUnitGUI::$ilAccess
protected

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

Referenced by __construct().

◆ $ilias

ilObjOrgUnitGUI::$ilias

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

Referenced by __construct().

◆ $ilLocator

ilObjOrgUnitGUI::$ilLocator
protected

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

Referenced by __construct().

◆ $ilLog

ilObjOrgUnitGUI::$ilLog
protected

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

Referenced by __construct().

◆ $object

ilObjOrgUnitGUI::$object

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

◆ $tabs_gui

ilObjOrgUnitGUI::$tabs_gui

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

◆ $toolbar

ilObjOrgUnitGUI::$toolbar
protected

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

◆ $tpl

ilObjOrgUnitGUI::$tpl

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

Referenced by __construct().

◆ $tree

ilObjOrgUnitGUI::$tree

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

Referenced by __construct(), and getTreeSelectorGUI().

◆ CMD_EDIT_SETTINGS

const ilObjOrgUnitGUI::CMD_EDIT_SETTINGS = 'editSettings'

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

Referenced by executeCommand(), and setSubTabsSettings().

◆ TAB_EXPORT

const ilObjOrgUnitGUI::TAB_EXPORT = 'export'

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

◆ TAB_GLOBAL_SETTINGS

const ilObjOrgUnitGUI::TAB_GLOBAL_SETTINGS = 'global_settings'

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

◆ TAB_ORGU_TYPES

const ilObjOrgUnitGUI::TAB_ORGU_TYPES = 'orgu_types'

Definition at line 31 of file class.ilObjOrgUnitGUI.php.

◆ TAB_POSITIONS

const ilObjOrgUnitGUI::TAB_POSITIONS = 'positions'

Definition at line 30 of file class.ilObjOrgUnitGUI.php.

Referenced by ilOrgUnitPositionGUI\getActiveTabId().

◆ TAB_SETTINGS

const ilObjOrgUnitGUI::TAB_SETTINGS = "settings"

Definition at line 32 of file class.ilObjOrgUnitGUI.php.

◆ TAB_STAFF

const ilObjOrgUnitGUI::TAB_STAFF = 'orgu_staff'

Definition at line 33 of file class.ilObjOrgUnitGUI.php.

◆ TAB_VIEW_CONTENT

const ilObjOrgUnitGUI::TAB_VIEW_CONTENT = 'view_content'

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


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