ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilObject2GUI Class Reference

New implementation of ilObjectGUI. More...

+ Inheritance diagram for ilObject2GUI:
+ Collaboration diagram for ilObject2GUI:

Public Member Functions

 __construct (int $id=0, int $id_type=self::REPOSITORY_NODE_ID, int $parent_node_id=0)
 
 executeCommand ()
 execute command More...
 
 getIdType ()
 
 delete ()
 Display delete confirmation form (repository/workspace switch) More...
 
 confirmedDelete ()
 Delete objects (repository/workspace switch) More...
 
 getHTML ()
 
 withReferences ()
 Final/Private declaration of unchanged parent methods. More...
 
 setCreationMode (bool $mode=true)
 If true, a creation screen is displayed the current [ref_id] does belong to the parent class The mode is determined in ilRepositoryGUI. More...
 
 getCreationMode ()
 
 prepareOutput (bool $show_sub_objects=true)
 
 isVisible (int $ref_id, string $type)
 
 setColumnSettings (ilColumnGUI $column_gui)
 
 view ()
 view object content (repository/workspace switch) More...
 
 getType ()
 Functions that must be overwritten. More...
 
 create ()
 CRUD. More...
 
 save ()
 
 edit ()
 
 update ()
 
 cancel ()
 
 putObjectInTree (ilObject $obj, ?int $parent_node_id=null)
 Add object to tree at given position. More...
 
- Public Member Functions inherited from ilObjectGUI
 getRefId ()
 
 setAdminMode (string $mode)
 
 getAdminMode ()
 
 getObject ()
 
 executeCommand ()
 
 withReferences ()
 determines whether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode (bool $mode=true)
 If true, a creation screen is displayed the current [ref_id] does belong to the parent class The mode is determined in ilRepositoryGUI. More...
 
 getCreationMode ()
 
 prepareOutput (bool $show_sub_objects=true)
 
 getAdminTabs ()
 administration tabs show only permissions and trash folder More...
 
 getHTML ()
 
 confirmedDeleteObject ()
 confirmed deletion of object -> objects are moved to trash or deleted immediately, if trash is disabled More...
 
 cancelObject ()
 cancel action and go back to previous page More...
 
 createObject ()
 create new object form More...
 
 editAvailabilityPeriodObject ()
 
 saveAvailabilityPeriodObject ()
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 
 getDidacticTemplateVar (string $type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $obj, ?int $parent_node_id=null)
 Add object to tree at given position. More...
 
 editObject ()
 
 addExternalEditFormCustom (ilPropertyFormGUI $form)
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction (string $cmd, string $default_form_action="")
 Get form action for command (command is method name without "Object", e.g. More...
 
 isVisible (int $ref_id, string $type)
 
 viewObject ()
 viewObject container presentation for "administration -> repository, trash, permissions" More...
 
 deleteObject (bool $error=false)
 Display deletion confirmation screen. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 
 addToDeskObject ()
 
 removeFromDeskObject ()
 
- Public Member Functions inherited from ILIAS\Object\ImplementsCreationCallback
 callCreationCallback (\ilObject $object, \ilObjectDefinition $obj_definition, int $requested_crtcb)
 

Static Public Member Functions

static handleAfterSaveCallback (ilObject $obj, ?int $callback_ref_id)
 After creation callback. 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

const OBJECT_ID = 0
 
const REPOSITORY_NODE_ID = 1
 
const WORKSPACE_NODE_ID = 2
 
const REPOSITORY_OBJECT_ID = 3
 
const WORKSPACE_OBJECT_ID = 4
 
const PORTFOLIO_OBJECT_ID = 5
 
- Data Fields inherited from ilObjectGUI
const ADMIN_MODE_NONE = ""
 
const ADMIN_MODE_SETTINGS = "settings"
 
const ADMIN_MODE_REPOSITORY = "repository"
 
const UPLOAD_TYPE_LOCAL = 1
 
const UPLOAD_TYPE_UPLOAD_DIRECTORY = 2
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 
const SUPPORTED_IMPORT_MIME_TYPES = [MimeType::APPLICATION__ZIP, MimeType::APPLICATION__X_ZIP_COMPRESSED]
 

Protected Member Functions

 afterConstructor ()
 Do anything that should be done after constructor in here. More...
 
 assignObject ()
 create object instance as internal property (repository/workspace switch) More...
 
 getAccessHandler ()
 
 setLocator ()
 set Locator More...
 
 deleteConfirmedObjects ()
 Delete objects (workspace specific) This should probably be moved elsewhere as done with RepUtil. More...
 
 setTitleAndDescription ()
 
 omitLocator (bool $omit=true)
 
 getTargetFrame (string $cmd, string $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...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 checkPermission (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 showPossibleSubObjects ()
 show possible sub objects (pull down menu) 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...
 
 addAdminLocatorItems (bool $do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 setTabs ()
 create tabs (repository/workspace switch) More...
 
 getReturnLocation (string $cmd, string $location="")
 Deprecated functions. More...
 
 setReturnLocation (string $cmd, string $location)
 set specific return location for command More...
 
 showActions ()
 
 getTabs ()
 @abstract overwrite in derived GUI class of your object type More...
 
 addLocatorItems ()
 Functions to be overwritten. More...
 
 checkPermissionBool (string $perm, string $cmd="", string $type="", ?int $node_id=null)
 
 initHeaderAction (?string $sub_type=null, ?int $sub_id=null)
 Add header action menu. More...
 
 redrawHeaderAction ()
 Updating icons after ajax call. More...
 
- Protected Member Functions inherited from ilObjectGUI
 getObjectService ()
 
 assignObject ()
 
 setTitleAndDescription ()
 
 createActionDispatcherGUI ()
 
 initHeaderAction (?string $sub_type=null, ?int $sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction (?ilObjectListGUI $list_gui=null)
 Insert header action into main template. More...
 
 addHeaderAction ()
 Add header action menu. More...
 
 redrawHeaderActionObject ()
 Ajax call: redraw action header only. More...
 
 setTabs ()
 set admin tabs More...
 
 setAdminTabs ()
 set admin tabs More...
 
 setLocator ()
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator (bool $omit=true)
 
 addAdminLocatorItems (bool $do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 getCreationFormsHTML (StandardForm|ilPropertyFormGUI|array $form)
 
 getTitleForCreationFormPage ()
 
 getCreationFormTitle ()
 
 initCreateForm (string $new_type)
 
 didacticTemplatesToForm ()
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 
 retrieveAdditionalDidacticTemplateOptions ()
 
 addAdoptContentLinkToToolbar ()
 
 addImportButtonToToolbar ()
 
 addAvailabilityPeriodButtonToToolbar (ilToolbarGUI $toolbar)
 
 parseDidacticTemplateVar (string $var, string $type)
 
 afterSave (ilObject $new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 routeImportCmdObject ()
 
 importFile (string $file_to_import, string $path_to_uploaded_file_in_temp_dir)
 
 deleteUploadedImportFile (string $path_to_uploaded_file_in_temp_dir)
 
 afterImport (ilObject $new_object)
 Post (successful) object import hook. More...
 
 setFormAction (string $cmd, string $form_action)
 
 getReturnLocation (string $cmd, string $default_location="")
 Get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation (string $cmd, string $location)
 set specific return location for command More...
 
 getTargetFrame (string $cmd, string $default_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame (string $cmd, string $target_frame)
 Set specific target frame for command. More...
 
 showPossibleSubObjects ()
 show possible sub objects (pull down menu) More...
 
 getTabs ()
 @abstract overwrite in derived GUI class of your object type More...
 
 redirectToRefId (int $ref_id, string $cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current ["ref_id"] value of the request More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 checkPermission (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 checkPermissionBool (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 getCreatableObjectTypes ()
 
 buildAddNewItemElements (array $subtypes, string $create_target_class=ilRepositoryGUI::class, ?int $redirect_target_ref_id=null,)
 
 buildGroup (string $create_target_class, array $obj_types_in_group, string $title, array $subtypes)
 

Protected Attributes

ilObjectDefinition $obj_definition
 
ilGlobalTemplateInterface $tpl
 
ilCtrl $ctrl
 
ilLanguage $lng
 
ilTabsGUI $tabs_gui
 
ilFavouritesManager $favourites
 
ilErrorHandling $error
 
ilLocatorGUI $locator
 
ilObjUser $user
 
ilAccessHandler $access
 
ilToolbarGUI $toolbar
 
Factory $refinery
 
ilRbacAdmin $rbac_admin
 
ilRbacSystem $rbac_system
 
ilRbacReview $rbac_review
 
int $request_ref_id
 
int $id_type
 
int $parent_id
 
string $type
 
string $html
 
int $object_id
 
int $node_id = null
 
array $creation_forms = []
 
 $access_handler
 
- Protected Attributes inherited from ilObjectGUI
ILIAS Notes Service $notes_service
 
GlobalHttpState $http
 
ServerRequestInterface $request
 
ilLocatorGUI $locator
 
ilObjUser $user
 
ilAccessHandler $access
 
ilSetting $settings
 
ilToolbarGUI $toolbar
 
ilRbacAdmin $rbac_admin
 
ilRbacSystem $rbac_system
 
ilRbacReview $rbac_review
 
ilObjectService $object_service
 
ilObjectDefinition $obj_definition
 
ilGlobalTemplateInterface $tpl
 
ilTree $tree
 
ilCtrl $ctrl
 
ilErrorHandling $error
 
ilLanguage $lng
 
ilTabsGUI $tabs_gui
 
ILIAS $ilias
 
ArrayBasedRequestWrapper $post_wrapper
 
RequestWrapper $request_wrapper
 
Refinery $refinery
 
ilFavouritesManager $favourites
 
CustomIconFactory $custom_icon_factory
 
UIFactory $ui_factory
 
UIRenderer $ui_renderer
 
Filesystem $temp_file_system
 
ilObject $object = null
 
bool $creation_mode = false
 
 $data
 
int $id
 
bool $call_by_reference = false
 
bool $prepare_output
 
int $ref_id
 
int $obj_id
 
int $maxcount
 
array $form_action = []
 
array $return_location = []
 
array $target_frame = []
 
string $tmp_import_dir
 
string $sub_objects = ""
 
bool $omit_locator = false
 
string $type = ""
 
string $admin_mode = self::ADMIN_MODE_NONE
 
int $requested_ref_id = 0
 
int $requested_crtptrefid = 0
 
int $requested_crtcb = 0
 
string $requested_new_type = ""
 
string $link_params
 
string $html = ""
 

Private Attributes

ilObjectRequestRetriever $retriever
 

Detailed Description

New implementation of ilObjectGUI.

(beta)

Differences to the ilObject implementation:

  • no $this->tree anymore
  • no $this->formaction anymore
  • no $this->return_location anymore
  • no $this->target_frame anymore
  • no $this->actions anymore
  • no $this->sub_objects anymore
  • no $this->data anymore
  • no $this->prepare_output anymore

All new modules should derive from this class.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e

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

Constructor & Destructor Documentation

◆ __construct()

ilObject2GUI::__construct ( int  $id = 0,
int  $id_type = self::REPOSITORY_NODE_ID,
int  $parent_node_id = 0 
)

Reimplemented in ilObjBlogGUI, ilObjCmiXapiGUI, ilObjContactAdministrationGUI, ilObjContentPageGUI, ilObjCourseVerificationGUI, ilObjDataCollectionGUI, ilObjFileGUI, ilObjHelpSettingsGUI, ilObjLegalNoticeGUI, ilObjItemGroupGUI, ilObjLTIConsumerGUI, ilObjMediaPoolGUI, ilObjPollGUI, ilObjPortfolioBaseGUI, ilObjPortfolioTemplateGUI, ilObjTermsOfServiceGUI, ilObjWikiSettingsGUI, ilObjWorkspaceRootFolderGUI, ilOrgUnitExtensionGUI, and ilObjFileServicesGUI.

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

84 {
85 global $DIC;
86
87 $this->obj_definition = $DIC["objDefinition"];
88 $this->tpl = $DIC["tpl"];
89 $this->ctrl = $DIC["ilCtrl"];
90 $this->lng = $DIC["lng"];
91 $this->tabs_gui = $DIC["ilTabs"];
92 $this->object_service = $DIC->object();
93 $this->favourites = new ilFavouritesManager();
94 $this->error = $DIC['ilErr'];
95 $this->locator = $DIC["ilLocator"];
96 $this->user = $DIC->user();
97 $this->access = $DIC->access();
98 $this->toolbar = $DIC->toolbar();
99 $this->http = $DIC['http'];
100 $this->request = $this->http->request();
101 $this->post_wrapper = $this->http->wrapper()->post();
102 $this->request_wrapper = $this->http->wrapper()->query();
103 $this->refinery = $DIC->refinery();
104 $this->retriever = new ilObjectRequestRetriever($DIC->http()->wrapper(), $this->refinery);
105 $this->rbac_admin = $DIC->rbac()->admin();
106 $this->rbac_system = $DIC->rbac()->system();
107 $this->rbac_review = $DIC->rbac()->review();
108 $this->ui_factory = $DIC['ui.factory'];
109 $this->ui_renderer = $DIC['ui.renderer'];
110 $this->settings = $DIC['ilSetting'];
111 $this->temp_file_system = $DIC->filesystem()->temp();
112
113 $tree = $DIC["tree"];
114
115 $this->requested_ref_id = 0;
116 if ($this->request_wrapper->has("ref_id")) {
117 $this->requested_ref_id = $this->request_wrapper->retrieve("ref_id", $this->refinery->kindlyTo()->int());
118 }
119 $this->id_type = $id_type;
120 $this->parent_id = $parent_node_id;
121 $this->type = $this->getType();
122 $this->html = "";
123 $this->notes_service = $DIC->notes();
124
125 $this->requested_new_type = '';
126 if ($this->request_wrapper->has("new_type")) {
127 $this->requested_new_type = $this->request_wrapper->retrieve(
128 "new_type",
129 $this->refinery->kindlyTo()->string()
130 );
131 } elseif ($this->post_wrapper->has("new_type")) {
132 $this->requested_new_type = $this->post_wrapper->retrieve(
133 "new_type",
134 $this->refinery->kindlyTo()->string()
135 );
136 }
137
138 $params = [];
139 switch ($this->id_type) {
141 $this->node_id = $id;
142 $this->object_id = ilObject::_lookupObjectId($this->node_id);
143 $this->tree = $tree;
144 $this->access_handler = $this->access;
145 $this->call_by_reference = true; // needed for prepareOutput()
146 $params[] = "ref_id";
147 break;
148
150 $this->object_id = $id;
151 $this->tree = $tree;
152 $this->access_handler = $this->access;
153 $params[] = "obj_id"; // ???
154 break;
155
157 $ilUser = $DIC["ilUser"];
158 $this->node_id = $id;
159 $this->tree = new ilWorkspaceTree($ilUser->getId());
160 $this->object_id = $this->tree->lookupObjectId($this->node_id);
161 $this->access_handler = new ilWorkspaceAccessHandler($this->tree);
162 $params[] = "wsp_id";
163 break;
164
166 $ilUser = $DIC["ilUser"];
167 $this->object_id = $id;
168 $this->tree = new ilWorkspaceTree($ilUser->getId());
169 $this->access_handler = new ilWorkspaceAccessHandler($this->tree);
170 $params[] = "obj_id"; // ???
171 break;
172
174 $this->object_id = $id;
175 $this->access_handler = new ilPortfolioAccessHandler();
176 $params[] = "prt_id";
177 break;
178
179 case self::OBJECT_ID:
180 $this->object_id = $id;
181 $this->access_handler = new ilDummyAccessHandler();
182 $params[] = "obj_id";
183 break;
184 }
185 $this->ctrl->saveParameter($this, $params);
186
187
188
189 // old stuff for legacy code (obsolete?)
190 if (!$this->object_id) {
191 $this->creation_mode = true;
192 }
193 if ($this->node_id) {
194 // add parent node id if missing
195 if (!$this->parent_id && $this->tree) {
196 $this->parent_id = $this->tree->getParentId($this->node_id);
197 }
198 }
199 $this->ref_id = $this->node_id ?? 0;
200 $this->obj_id = $this->object_id;
201
202 $this->assignObject();
203
204 // set context
205 if (is_object($this->object)) {
206 $this->ctrl->setContextObject($this->object->getId(), $this->object->getType());
207 }
208
209 $this->afterConstructor();
210 }
error(string $a_errmsg)
Manages favourites, currently the interface for other components, needs discussion.
getType()
Functions that must be overwritten.
ilAccessHandler $access
assignObject()
create object instance as internal property (repository/workspace switch)
afterConstructor()
Do anything that should be done after constructor in here.
Base class for all sub item list gui's.
static _lookupObjectId(int $ref_id)
Access handler for portfolio NOTE: This file needs to stay in the classes directory,...
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...
if(! $DIC->user() ->getId()||!ilLTIConsumerAccess::hasCustomProviderCreationAccess()) $params
Definition: ltiregstart.php:31
static http()
Fetches the global http state from ILIAS.
global $DIC
Definition: shib_login.php:26

References $access, $DIC, ilObjectGUI\$id, $id_type, $object_id, $params, ilObjectGUI\$tree, ilObject\_lookupObjectId(), ILIAS\Repository\access(), afterConstructor(), assignObject(), ILIAS\Repository\ctrl(), error(), getType(), ILIAS\Repository\html(), ILIAS\FileDelivery\http(), ILIAS\Repository\lng(), ILIAS\Repository\locator(), ILIAS\Repository\object(), OBJECT_ID, PORTFOLIO_OBJECT_ID, ILIAS\Repository\refinery(), REPOSITORY_NODE_ID, REPOSITORY_OBJECT_ID, ILIAS\Repository\settings(), ILIAS\Repository\toolbar(), ILIAS\Repository\user(), WORKSPACE_NODE_ID, and WORKSPACE_OBJECT_ID.

+ Here is the call graph for this function:

Member Function Documentation

◆ addAdminLocatorItems()

ilObject2GUI::addAdminLocatorItems ( bool  $do_not_add_object = false)
finalprotected

should be overwritten to add object specific items (repository items are preloaded)

Reimplemented from ilObjectGUI.

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

509 : void
510 {
511 parent::addAdminLocatorItems($do_not_add_object);
512 }

Referenced by ilObjectPluginGUI\executeCommand().

+ Here is the caller graph for this function:

◆ addLocatorItems()

ilObject2GUI::addLocatorItems ( )
protected

Functions to be overwritten.

Reimplemented from ilObjectGUI.

Reimplemented in ilObjBibliographicGUI, ilObjBlogGUI, ilObjCmiXapiGUI, ilObjContentPageGUI, ilObjDataCollectionGUI, ilObjFileGUI, ilObjItemGroupGUI, ilObjLTIConsumerGUI, ilObjMediaPoolGUI, ilObjPollGUI, ilObjPortfolioBaseGUI, ilObjectPluginGUI, and ilObjLinkResourceGUI.

Definition at line 600 of file class.ilObject2GUI.php.

600 : void
601 {
602 }

Referenced by setLocator().

+ Here is the caller graph for this function:

◆ afterConstructor()

ilObject2GUI::afterConstructor ( )
protected

Do anything that should be done after constructor in here.

Reimplemented in ilObjItemGroupGUI, and ilObjMediaPoolGUI.

Definition at line 215 of file class.ilObject2GUI.php.

215 : void
216 {
217 }

Referenced by __construct().

+ Here is the caller graph for this function:

◆ assignObject()

ilObject2GUI::assignObject ( )
finalprotected

create object instance as internal property (repository/workspace switch)

Reimplemented from ilObjectGUI.

Definition at line 259 of file class.ilObject2GUI.php.

259 : void
260 {
261 if ($this->object_id != 0) {
262 switch ($this->id_type) {
263 case self::OBJECT_ID:
267 $this->object = ilObjectFactory::getInstanceByObjId($this->object_id);
268 break;
269
271 $this->object = ilObjectFactory::getInstanceByRefId($this->node_id);
272 break;
273
275 // to be discussed
276 $this->object = ilObjectFactory::getInstanceByObjId($this->object_id);
277 break;
278 }
279 }
280 }
static getInstanceByRefId(int $ref_id, bool $stop_on_error=true)
get an instance of an Ilias object by reference id
static getInstanceByObjId(?int $obj_id, bool $stop_on_error=true)
get an instance of an Ilias object by object id

References ilObjectFactory\getInstanceByObjId(), ilObjectFactory\getInstanceByRefId(), OBJECT_ID, PORTFOLIO_OBJECT_ID, REPOSITORY_NODE_ID, REPOSITORY_OBJECT_ID, WORKSPACE_NODE_ID, and WORKSPACE_OBJECT_ID.

Referenced by ilObjAdministrativeNotificationGUI\__construct(), ilObjFooterAdministrationGUI\__construct(), ilObjMainMenuGUI\__construct(), and __construct().

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

◆ cancel()

ilObject2GUI::cancel ( )

Reimplemented in ilObjTaxonomyGUI.

Definition at line 628 of file class.ilObject2GUI.php.

628 : void
629 {
630 parent::cancelObject();
631 }

◆ checkPermission()

ilObject2GUI::checkPermission ( string  $perm,
string  $cmd = "",
string  $type = "",
?int  $ref_id = null 
)
finalprotected

Reimplemented from ilObjectGUI.

Definition at line 489 of file class.ilObject2GUI.php.

494 : void {
495 parent::checkPermission($perm, $cmd, $type, $ref_id);
496 }

Referenced by ilObjHelpSettingsGUI\activateModule(), ilObjLinkResourceGUI\addLink(), ilObjMediaPoolGUI\allMedia(), ilObjHelpSettingsGUI\confirmHelpModulesDeletion(), ilObjMediaPoolGUI\confirmRemove(), ilObjMediaPoolGUI\copyToClipboard(), ilObjMediaPoolGUI\createFolderForm(), ilObjHelpSettingsGUI\deactivateModule(), ilObjHelpSettingsGUI\deleteHelpModules(), ilObjLinkResourceGUI\deleteParameter(), ilObjLinkResourceGUI\deleteParameterForm(), ilObjMediaPoolGUI\editFolder(), ilObjLinkResourceGUI\editLink(), ilObjBlogGUI\executeCommand(), ilObjDataCollectionGUI\executeCommand(), ilObjMediaPoolGUI\executeCommand(), ilObjPortfolioTemplateGUI\executeCommand(), ilObjectPluginGUI\executeCommand(), ilObjLinkResourceGUI\executeCommand(), ilObjectPluginGUI\infoScreen(), ilObjBlogGUI\infoScreenForward(), ilObjDataCollectionGUI\infoScreenForward(), ilObjPortfolioTemplateGUI\infoScreenForward(), ilObjMediaPoolGUI\insertFromClipboard(), ilObjItemGroupGUI\listMaterials(), ilObjMediaPoolGUI\listMedia(), ilObjMediaPoolGUI\openClipboard(), ilObjMediaPoolGUI\remove(), ilObjLinkResourceGUI\saveAddLink(), ilObjContactAdministrationGUI\saveConfigurationForm(), ilObjMediaPoolGUI\saveFolder(), ilObjItemGroupGUI\saveItemAssignment(), ilObjLinkResourceGUI\saveLinkList(), ilObjHelpSettingsGUI\saveOrdering(), ilObjHelpSettingsGUI\setMode(), ilObjLinkResourceGUI\settings(), ilObjMediaPoolGUI\showMedia(), ilObjMediaPoolGUI\showPreview(), ilObjMediaPoolGUI\updateFolder(), ilObjLinkResourceGUI\updateLinks(), and ilObjContentPageGUI\view().

+ Here is the caller graph for this function:

◆ checkPermissionBool()

ilObject2GUI::checkPermissionBool ( string  $perm,
string  $cmd = "",
string  $type = "",
?int  $node_id = null 
)
protected

Reimplemented from ilObjectGUI.

Reimplemented in ilObjPortfolioGUI, and ilObjTaxonomyGUI.

Definition at line 712 of file class.ilObject2GUI.php.

717 : bool {
718 if ($perm == "create") {
719 if (!$node_id) {
721 }
722 if ($node_id) {
723 return $this->getAccessHandler()->checkAccess($perm . "_" . $type, $cmd, $node_id);
724 }
725 } else {
726 if (!$node_id) {
728 }
729 if ($node_id) {
730 return $this->getAccessHandler()->checkAccess($perm, $cmd, $node_id);
731 }
732 }
733
734 // if we do not have a node id, check if current user is owner
735 if ($this->obj_id && $this->object->getOwner() == $this->user->getId()) {
736 return true;
737 }
738 return false;
739 }

Referenced by ilObjWorkspaceFolderGUI\addContentSubTabs(), ilObjContentPageGUI\addToNavigationHistory(), ilObjPollGUI\confirmDeleteAllVotes(), ilObjWorkspaceFolderGUI\cut(), ilObjPollGUI\deleteAllVotes(), ilObjWorkspaceFolderGUI\deleteConfirmation(), ilObjPortfolioBaseGUI\determinePageCall(), ilObjDataCollectionGUI\edit(), ilObjItemGroupGUI\edit(), ilObjBibliographicGUI\editObject(), ilRemoteObjectBaseGUI\editObject(), ilObjHelpSettingsGUI\editSettings(), ilObjBlogGUI\executeCommand(), ilObjDataCollectionGUI\executeCommand(), ilObjLegalNoticeGUI\executeCommand(), ilObjItemGroupGUI\executeCommand(), ilRemoteObjectBaseGUI\executeCommand(), ilObjContactAdministrationGUI\getAdminTabs(), ilObjHelpSettingsGUI\getAdminTabs(), ilObjWikiSettingsGUI\getAdminTabs(), ilObjContactAdministrationGUI\getConfigurationForm(), ilObjContentPageGUI\getContent(), ilObjBlogGUI\infoScreenForward(), ilObjCmiXapiGUI\infoScreenForward(), ilObjContentPageGUI\infoScreenForward(), ilObjDataCollectionGUI\infoScreenForward(), ilObjPortfolioTemplateGUI\infoScreenForward(), ilObjWikiSettingsGUI\initForm(), ilObjWorkspaceFolderGUI\performPasteIntoMultipleObjects(), ilObjBlogGUI\render(), ilObjPollGUI\render(), ilObjContentPageGUI\renderHeaderActions(), ilObjItemGroupGUI\save(), ilObjBibliographicGUI\saveObject(), ilObjLTIConsumerGUI\saveObject(), ilObjLinkResourceGUI\saveObject(), ilObjWikiSettingsGUI\saveSettings(), ilObjHelpSettingsGUI\setMode(), ilObjContentPageGUI\setSettingsSubTabs(), ilObjBlogGUI\setTabs(), ilObjContentPageGUI\setTabs(), ilObjPollGUI\setTabs(), ilObjPortfolioTemplateGUI\setTabs(), ilRemoteObjectBaseGUI\setTabs(), ilObjPollGUI\showParticipants(), ilObjPollGUI\showParticipantVotes(), ilObjDataCollectionGUI\update(), ilRemoteObjectBaseGUI\updateObject(), and ilObjHelpSettingsGUI\uploadHelpFile().

+ Here is the caller graph for this function:

◆ confirmedDelete()

ilObject2GUI::confirmedDelete ( )

Delete objects (repository/workspace switch)

Reimplemented in ilObjTaxonomyGUI.

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

366 : void
367 {
368 switch ($this->id_type) {
371 parent::confirmedDeleteObject();
372
373 // no break
376 $this->deleteConfirmedObjects();
377
378 // no break
379 case self::OBJECT_ID:
381 // :TODO: should this ever occur?
382 break;
383 }
384 }
deleteConfirmedObjects()
Delete objects (workspace specific) This should probably be moved elsewhere as done with RepUtil.

References deleteConfirmedObjects(), OBJECT_ID, PORTFOLIO_OBJECT_ID, REPOSITORY_NODE_ID, REPOSITORY_OBJECT_ID, WORKSPACE_NODE_ID, and WORKSPACE_OBJECT_ID.

+ Here is the call graph for this function:

◆ create()

ilObject2GUI::create ( )

◆ delete()

ilObject2GUI::delete ( )

Display delete confirmation form (repository/workspace switch)

Definition at line 343 of file class.ilObject2GUI.php.

343 : void
344 {
345 switch ($this->id_type) {
348 parent::deleteObject();
349
350 // no break
353 $this->deleteConfirmation();
354
355 // no break
356 case self::OBJECT_ID:
358 // :TODO: should this ever occur?
359 break;
360 }
361 }

References OBJECT_ID, PORTFOLIO_OBJECT_ID, REPOSITORY_NODE_ID, REPOSITORY_OBJECT_ID, WORKSPACE_NODE_ID, and WORKSPACE_OBJECT_ID.

◆ deleteConfirmedObjects()

ilObject2GUI::deleteConfirmedObjects ( )
protected

Delete objects (workspace specific) This should probably be moved elsewhere as done with RepUtil.

Definition at line 390 of file class.ilObject2GUI.php.

390 : void
391 {
392 if (!$this->post_wrapper->has("id")) {
393 $this->tpl->setOnScreenMessage("failure", $this->lng->txt("no_checkbox"), true);
394 $this->ctrl->redirect($this, "");
395 return;
396 }
397
398 $ids = $this->post_wrapper->retrieve(
399 "id",
400 $this->refinery->kindlyTo()->listOf($this->refinery->kindlyTo()->int())
401 );
402
403 if (count($ids) == 0) {
404 $this->tpl->setOnScreenMessage("failure", $this->lng->txt("no_checkbox"), true);
405 $this->ctrl->redirect($this, "");
406 return;
407 }
408
409 // #18797 - because of parent/child relations gather all nodes first
410 $del_nodes = [];
411 foreach ($ids as $node_id) {
412 $del_nodes[$node_id] = $this->tree->getNodeData($node_id);
413 }
414
415 foreach ($del_nodes as $node_id => $node) {
416 $this->tree->deleteReference($node_id);
417 if ($this->tree->isInTree($node_id)) {
418 $this->tree->deleteTree($node);
419 }
420
421 $this->getAccessHandler()->removePermission($node_id);
422
423 $object = ilObjectFactory::getInstanceByObjId((int) $node["obj_id"], false);
424 if ($object) {
425 $object->delete();
426 }
427 }
428
429 $this->tpl->setOnScreenMessage("success", $this->lng->txt("msg_removed"), true);
430 $this->ctrl->redirect($this, "");
431 }
delete()
delete object or referenced object (in the case of a referenced object, object data is only deleted i...

References $node_id, ilObjectGUI\$object, ILIAS\Repository\ctrl(), ilObject\delete(), getAccessHandler(), ilObjectFactory\getInstanceByObjId(), ILIAS\Repository\lng(), and ILIAS\Repository\refinery().

Referenced by confirmedDelete().

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

◆ edit()

ilObject2GUI::edit ( )

Reimplemented in ilObjBlogGUI, ilObjDataCollectionGUI, ilObjFileGUI, ilObjItemGroupGUI, ilObjMediaPoolGUI, ilObjPortfolioGUI, ilObjPortfolioTemplateGUI, and ilObjWorkspaceFolderGUI.

Definition at line 620 of file class.ilObject2GUI.php.

620 : void
621 {
622 parent::editObject();
623 }

◆ executeCommand()

ilObject2GUI::executeCommand ( )

execute command

Reimplemented from ilObjectGUI.

Reimplemented in ilObjAdministrativeNotificationGUI, ilObjBibliographicGUI, ilObjBlogGUI, ilObjContactAdministrationGUI, ilObjDataCollectionGUI, ilObjDataProtectionGUI, ilObjFileServicesGUI, ilObjFooterAdministrationGUI, ilObjHelpSettingsGUI, ilObjLegalNoticeGUI, ilObjItemGroupGUI, ilObjLegalDocumentsGUI, ilObjMainMenuGUI, ilObjMediaPoolGUI, ilObjPollGUI, ilObjPortfolioGUI, ilObjPortfolioTemplateGUI, ilObjectPluginGUI, ilObjTaxonomyGUI, ilObjTermsOfServiceGUI, ilObjLinkResourceGUI, ilRemoteObjectBaseGUI, ilObjWikiSettingsGUI, and ilObjWorkspaceFolderGUI.

Definition at line 222 of file class.ilObject2GUI.php.

222 : void
223 {
224 $next_class = $this->ctrl->getNextClass($this);
225 $cmd = $this->ctrl->getCmd();
226
227 $this->prepareOutput();
228
229 switch ($next_class) {
230 case "ilworkspaceaccessgui":
231 if ($this->node_id) {
232 $this->tabs_gui->activateTab("id_permissions");
233 $wspacc = new ilWorkspaceAccessGUI($this->node_id, $this->getAccessHandler());
234 $this->ctrl->forwardCommand($wspacc);
235 } else {
236 if (!$cmd) {
237 $cmd = "render";
238 }
239 $this->$cmd();
240 }
241 break;
242
243 default:
244 if (!$cmd) {
245 $cmd = "render";
246 }
247 $this->$cmd();
248 }
249 }
prepareOutput(bool $show_sub_objects=true)

References ILIAS\Repository\ctrl(), getAccessHandler(), and prepareOutput().

Referenced by ilObjPortfolioTemplateGUI\executeCommand().

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

◆ getAccessHandler()

◆ getCenterColumnHTML()

ilObject2GUI::getCenterColumnHTML ( )
finalprotected

Get center column.

Reimplemented from ilObjectGUI.

Definition at line 477 of file class.ilObject2GUI.php.

477 : string
478 {
479 return parent::getCenterColumnHTML();
480 }

◆ getCreationMode()

◆ getHTML()

ilObject2GUI::getHTML ( )

Reimplemented from ilObjectGUI.

Definition at line 433 of file class.ilObject2GUI.php.

433 : string
434 {
435 return parent::getHTML();
436 }

◆ getIdType()

ilObject2GUI::getIdType ( )

Definition at line 251 of file class.ilObject2GUI.php.

251 : int
252 {
253 return $this->id_type;
254 }

References $id_type.

Referenced by ilObjFileAbstractZipProcessor\__construct(), and ilObjLinkResourceGUI\executeCommand().

+ Here is the caller graph for this function:

◆ getReturnLocation()

ilObject2GUI::getReturnLocation ( string  $cmd,
string  $location = "" 
)
finalprotected

Deprecated functions.

Reimplemented from ilObjectGUI.

Definition at line 580 of file class.ilObject2GUI.php.

580 : string
581 {
582 die("ilObject2GUI::getReturnLocation() is deprecated.");
583 }

◆ getRightColumnHTML()

ilObject2GUI::getRightColumnHTML ( )
finalprotected

Display right column.

Reimplemented from ilObjectGUI.

Definition at line 481 of file class.ilObject2GUI.php.

481 : string
482 {
483 return parent::getRightColumnHTML();
484 }

◆ getTabs()

ilObject2GUI::getTabs ( )
finalprotected

@abstract overwrite in derived GUI class of your object type

Reimplemented from ilObjectGUI.

Definition at line 592 of file class.ilObject2GUI.php.

592 : void
593 {
594 die("ilObject2GUI::getTabs() is deprecated.");
595 }

◆ getTargetFrame()

ilObject2GUI::getTargetFrame ( string  $cmd,
string  $default_target_frame = "" 
)
finalprotected

get target frame for command (command is method name without "Object", e.g.

"perm")

Reimplemented from ilObjectGUI.

Definition at line 465 of file class.ilObject2GUI.php.

465 : string
466 {
467 return parent::getTargetFrame($cmd, $target_frame);
468 }

References ilObjectGUI\$target_frame.

◆ getType()

◆ handleAfterSaveCallback()

static ilObject2GUI::handleAfterSaveCallback ( ilObject  $obj,
?int  $callback_ref_id 
)
static

After creation callback.

Definition at line 694 of file class.ilObject2GUI.php.

695 {
696 global $DIC;
697 $objDefinition = $DIC["objDefinition"];
698
699 $callback_ref_id = (int) $callback_ref_id;
700 if ($callback_ref_id) {
701 $callback_type = ilObject::_lookupType($callback_ref_id, true);
702 $class_name = "ilObj" . $objDefinition->getClassName($callback_type) . "GUI";
703 if (strtolower($class_name) == "ilobjitemgroupgui") {
704 $callback_obj = new $class_name($callback_ref_id);
705 } else {
706 $callback_obj = new $class_name(null, $callback_ref_id, true, false);
707 }
708 $callback_obj->afterSaveCallback($obj);
709 }
710 }
static _lookupType(int $id, bool $reference=false)

References $DIC, ilObject\_lookupType(), and ILIAS\Repository\int().

+ Here is the call graph for this function:

◆ initHeaderAction()

ilObject2GUI::initHeaderAction ( ?string  $sub_type = null,
?int  $sub_id = null 
)
protected

Add header action menu.

Reimplemented from ilObjectGUI.

Reimplemented in ilObjFileGUI, ilObjLTIConsumerGUI, and ilObjCmiXapiGUI.

Definition at line 744 of file class.ilObject2GUI.php.

745 {
746 if ($this->id_type == self::WORKSPACE_NODE_ID) {
747 if (!$this->creation_mode && $this->object_id) {
748 $dispatcher = new ilCommonActionDispatcherGUI(
750 $this->getAccessHandler(),
751 $this->getType(),
752 $this->node_id,
753 $this->object_id
754 );
755
756 $dispatcher->setSubObject($sub_type, $sub_id);
757
759 $this->ctrl->getLinkTarget($this, "redrawHeaderAction", "", true),
760 "",
761 $this->ctrl->getLinkTargetByClass(["ilcommonactiondispatchergui", "iltagginggui"], "")
762 );
763
764 $lg = $dispatcher->initHeaderAction();
765
766 if (is_object($lg)) {
767 // to enable add to desktop / remove from desktop
768 if ($this instanceof ilDesktopItemHandling) {
769 $lg->setContainerObject($this);
770 }
771
772 // for activation checks see ilObjectGUI
773 // $lg->enableComments(true);
774 $lg->enableNotes(true);
775 // $lg->enableTags(true);
776 }
777
778 return $lg;
779 }
780 }
781
782 return parent::initHeaderAction($sub_type, $sub_id);
783 }
Class ilCommonActionDispatcherGUI.
static prepareJsLinks(string $redraw_url, string $notes_url, string $tags_url, ?ilGlobalTemplateInterface $tpl=null)
Insert js/ajax links into template.

References ILIAS\Repository\ctrl(), ilObjectListGUI\prepareJsLinks(), and ilCommonActionDispatcherGUI\TYPE_WORKSPACE.

+ Here is the call graph for this function:

◆ isVisible()

ilObject2GUI::isVisible ( int  $ref_id,
string  $type 
)
final

Reimplemented from ilObjectGUI.

Definition at line 473 of file class.ilObject2GUI.php.

473 : bool
474 {
476 }

References ilObjectGUI\$ref_id, $type, and ILIAS\GlobalScreen\Scope\isVisible().

+ Here is the call graph for this function:

◆ omitLocator()

ilObject2GUI::omitLocator ( bool  $omit = true)
finalprotected

Reimplemented from ilObjectGUI.

Definition at line 461 of file class.ilObject2GUI.php.

461 : void
462 {
463 parent::omitLocator($omit);
464 }

◆ prepareOutput()

◆ putObjectInTree()

ilObject2GUI::putObjectInTree ( ilObject  $obj,
?int  $parent_node_id = null 
)

Add object to tree at given position.

Reimplemented from ilObjectGUI.

Reimplemented in ilObjFileGUI.

Definition at line 636 of file class.ilObject2GUI.php.

636 : void
637 {
638 $this->object_id = $obj->getId();
639
640 if (!$parent_node_id) {
641 $parent_node_id = $this->parent_id;
642 }
643
644 // add new object to custom parent container
645 if ($this->retriever->has('crtptrefid')) {
646 $parent_node_id = $this->retriever->getMaybeInt('crtptrefid') ?? 0;
647 }
648
649 switch ($this->id_type) {
652 if (!$this->node_id) {
653 $obj->createReference();
654 $this->node_id = $obj->getRefId();
655 }
656 $obj->putInTree($parent_node_id);
657 $obj->setPermissions($parent_node_id);
658
659 // rbac log
660 $rbac_log_roles = $this->rbac_review->getParentRoleIds($this->node_id, false);
661 $rbac_log = ilRbacLog::gatherFaPa($this->node_id, array_keys($rbac_log_roles), true);
662 ilRbacLog::add(ilRbacLog::CREATE_OBJECT, $this->node_id, $rbac_log);
663
664 $this->ctrl->setParameter($this, "ref_id", $this->node_id);
665 break;
666
669 if (!$this->node_id) {
670 $this->node_id = $this->tree->insertObject($parent_node_id, $this->object_id);
671 }
672 $this->getAccessHandler()->setPermissions($parent_node_id, $this->node_id);
673
674 $this->ctrl->setParameter($this, "wsp_id", $this->node_id);
675 break;
676
677 case self::OBJECT_ID:
679 // do nothing
680 break;
681 }
682
683 // BEGIN ChangeEvent: Record save object.
684 ilChangeEvent::_recordWriteEvent($this->object_id, $this->user->getId(), 'create');
685 // END ChangeEvent: Record save object.
686
687 // use forced callback after object creation
688 self::handleAfterSaveCallback($obj, $this->retriever->getMaybeInt('crtcb'));
689 }
static _recordWriteEvent(int $obj_id, int $usr_id, string $action, ?int $parent_obj_id=null)
Records a write event.
static handleAfterSaveCallback(ilObject $obj, ?int $callback_ref_id)
After creation callback.
setPermissions(int $parent_ref_id)
createReference()
creates reference for object
putInTree(int $parent_ref_id)
maybe this method should be in tree object!?
static add(int $action, int $ref_id, array $diff, bool $source_ref_id=false)
static gatherFaPa(int $ref_id, array $role_ids, bool $add_action=false)
const CREATE_OBJECT

References ilChangeEvent\_recordWriteEvent(), ilRbacLog\add(), ilRbacLog\CREATE_OBJECT, ilObject\createReference(), ILIAS\Repository\ctrl(), ilRbacLog\gatherFaPa(), ilObject\getId(), ilObject\getRefId(), ilObject\putInTree(), ilObject\setPermissions(), and ILIAS\Repository\user().

Referenced by ilObjLTIConsumerGUI\createNewObject(), ilObjCmiXapiVerificationGUI\save(), ilObjCourseVerificationGUI\save(), ilObjExerciseVerificationGUI\save(), ilObjItemGroupGUI\save(), ilObjLTIConsumerVerificationGUI\save(), ilObjSCORMVerificationGUI\save(), ilObjTestVerificationGUI\save(), ilObjBibliographicGUI\saveObject(), ilObjLTIConsumerGUI\saveObject(), and ilObjLinkResourceGUI\saveObject().

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

◆ redirectToRefId()

ilObject2GUI::redirectToRefId ( int  $ref_id,
string  $cmd = "" 
)
finalprotected

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

Reimplemented from ilObjectGUI.

Definition at line 502 of file class.ilObject2GUI.php.

502 : void
503 {
504 parent::redirectToRefId($ref_id, $cmd);
505 }

References $ref_id.

◆ redrawHeaderAction()

ilObject2GUI::redrawHeaderAction ( )
protected

Updating icons after ajax call.

Definition at line 788 of file class.ilObject2GUI.php.

788 : void
789 {
790 parent::redrawHeaderActionObject();
791 }

◆ save()

◆ setColumnSettings()

ilObject2GUI::setColumnSettings ( ilColumnGUI  $column_gui)
final

Reimplemented from ilObjectGUI.

Definition at line 485 of file class.ilObject2GUI.php.

485 : void
486 {
487 parent::setColumnSettings($column_gui);
488 }

◆ setCreationMode()

ilObject2GUI::setCreationMode ( bool  $mode = true)
final

If true, a creation screen is displayed the current [ref_id] does belong to the parent class The mode is determined in ilRepositoryGUI.

Reimplemented from ilObjectGUI.

Definition at line 445 of file class.ilObject2GUI.php.

445 : void
446 {
447 parent::setCreationMode($mode);
448 }

Referenced by ilObjMediaPoolGUI\executeCommand().

+ Here is the caller graph for this function:

◆ setLocator()

ilObject2GUI::setLocator ( )
protected

set Locator

Reimplemented from ilObjectGUI.

Reimplemented in ilOrgUnitExtensionGUI.

Definition at line 293 of file class.ilObject2GUI.php.

293 : void
294 {
295 if ($this->omit_locator) {
296 return;
297 }
298
299 switch ($this->id_type) {
301 $ref_id = $this->node_id ?: $this->parent_id;
302 $this->locator->addRepositoryItems($ref_id);
303
304 // not so nice workaround: todo: handle locator as tabs in ilTemplate
305 if ($this->admin_mode == self::ADMIN_MODE_NONE &&
306 strtolower($this->ctrl->getCmdClass()) == "ilobjrolegui") {
307 $this->ctrl->setParameterByClass(
308 "ilobjrolegui",
309 "rolf_ref_id",
310 $this->request_wrapper->has("rolf_ref_id")
311 ? $this->request_wrapper->retrieve("rolf_ref_id", $this->refinery->kindlyTo()->string())
312 : null
313 );
314 $this->ctrl->setParameterByClass(
315 "ilobjrolegui",
316 "obj_id",
317 $this->request_wrapper->retrieve("obj_id", $this->refinery->kindlyTo()->string())
318 );
319 $this->locator->addItem(
320 $this->lng->txt("role"),
321 $this->ctrl->getLinkTargetByClass(["ilpermissiongui",
322 "ilobjrolegui"], "perm")
323 );
324 }
325
326 // in workspace this is done in ilPersonalWorkspaceGUI
327 if ($this->object_id) {
328 $this->addLocatorItems();
329 }
330 $this->tpl->setLocator();
331
332 break;
333
335 // :TODO:
336 break;
337 }
338 }
addLocatorItems()
Functions to be overwritten.

References $parent_id, ilObjectGUI\$ref_id, addLocatorItems(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ILIAS\Repository\locator(), REPOSITORY_NODE_ID, and WORKSPACE_NODE_ID.

Referenced by ilObjBlogGUI\executeCommand(), ilObjMediaPoolGUI\executeCommand(), and ilObjectPluginGUI\executeCommand().

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

◆ setReturnLocation()

ilObject2GUI::setReturnLocation ( string  $cmd,
string  $location 
)
finalprotected

set specific return location for command

Reimplemented from ilObjectGUI.

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

584 : void
585 {
586 die("ilObject2GUI::setReturnLocation() is deprecated.");
587 }

◆ setTabs()

ilObject2GUI::setTabs ( )
protected

create tabs (repository/workspace switch)

this had to be moved here because of the context-specific permission tab

Reimplemented from ilObjectGUI.

Reimplemented in ilObjBlogGUI, ilObjCmiXapiGUI, ilObjContentPageGUI, ilObjDataCollectionGUI, ilObjFileGUI, ilObjItemGroupGUI, ilObjLTIConsumerGUI, ilObjMediaPoolGUI, ilObjPollGUI, ilObjPortfolioGUI, ilObjPortfolioTemplateGUI, ilObjLinkResourceGUI, and ilRemoteObjectBaseGUI.

Definition at line 542 of file class.ilObject2GUI.php.

542 : void
543 {
544 switch ($this->id_type) {
547 if ($this->checkPermissionBool("edit_permission")) {
548 $this->tabs_gui->addTab(
549 "id_permissions",
550 $this->lng->txt("perm_settings"),
551 $this->ctrl->getLinkTargetByClass([get_class($this), "ilpermissiongui"], "perm")
552 );
553 }
554 break;
555
558 // only files and blogs can be shared for now
559 if (
560 $this->checkPermissionBool("edit_permission") &&
561 in_array($this->type, ["file", "blog"]) &&
562 $this->node_id
563 ) {
564 $this->tabs_gui->addTab(
565 "id_permissions",
566 $this->lng->txt("wsp_permissions"),
567 $this->ctrl->getLinkTargetByClass([get_class($this), "ilworkspaceaccessgui"], "share")
568 );
569 }
570 break;
571 }
572 }
checkPermissionBool(string $perm, string $cmd="", string $type="", ?int $node_id=null)

References ILIAS\Repository\lng().

Referenced by ilObjectPluginGUI\executeCommand(), and ilObjPortfolioTemplateGUI\setTabs().

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

◆ setTargetFrame()

ilObject2GUI::setTargetFrame ( string  $cmd,
string  $target_frame 
)
finalprotected

Set specific target frame for command.

Reimplemented from ilObjectGUI.

Definition at line 469 of file class.ilObject2GUI.php.

469 : void
470 {
471 parent::setTargetFrame($cmd, $target_frame);
472 }

References ilObjectGUI\$target_frame.

◆ setTitleAndDescription()

ilObject2GUI::setTitleAndDescription ( )
protected

Reimplemented from ilObjectGUI.

Reimplemented in ilObjContentPageGUI, ilObjFileServicesGUI, ilObjPortfolioGUI, and ilObjWorkspaceRootFolderGUI.

Definition at line 457 of file class.ilObject2GUI.php.

457 : void
458 {
459 parent::setTitleAndDescription();
460 }

◆ showActions()

ilObject2GUI::showActions ( )
finalprotected

Definition at line 588 of file class.ilObject2GUI.php.

588 : void
589 {
590 die("ilObject2GUI::showActions() is deprecated.");
591 }

◆ showPossibleSubObjects()

ilObject2GUI::showPossibleSubObjects ( )
finalprotected

show possible sub objects (pull down menu)

Reimplemented from ilObjectGUI.

Definition at line 497 of file class.ilObject2GUI.php.

497 : void
498 {
499 parent::showPossibleSubObjects();
500 }

◆ update()

ilObject2GUI::update ( )

Reimplemented in ilObjDataCollectionGUI, and ilObjWorkspaceFolderGUI.

Definition at line 624 of file class.ilObject2GUI.php.

624 : void
625 {
626 parent::updateObject();
627 }

Referenced by ilObjDataProtectionGUI\form(), and ilObjTermsOfServiceGUI\form().

+ Here is the caller graph for this function:

◆ view()

ilObject2GUI::view ( )

view object content (repository/workspace switch)

Reimplemented in ilObjBibliographicGUI, ilObjContentPageGUI, ilObjDataProtectionGUI, ilObjPortfolioBaseGUI, and ilObjLinkResourceGUI.

Definition at line 517 of file class.ilObject2GUI.php.

517 : void
518 {
519 switch ($this->id_type) {
522 parent::viewObject();
523 break;
524
527 $this->render();
528
529 // no break
530 case self::OBJECT_ID:
532 // :TODO: should this ever occur? do nothing or edit() ?!
533 break;
534 }
535 }

◆ withReferences()

ilObject2GUI::withReferences ( )
final

Final/Private declaration of unchanged parent methods.

Reimplemented from ilObjectGUI.

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

441 : bool
442 {
443 return parent::withReferences();
444 }

Field Documentation

◆ $access

◆ $access_handler

◆ $creation_forms

array ilObject2GUI::$creation_forms = []
protected

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

◆ $ctrl

◆ $error

ilErrorHandling ilObject2GUI::$error
protected

Definition at line 58 of file class.ilObject2GUI.php.

Referenced by ilObjLTIConsumerGUI\addDynReg().

◆ $favourites

ilFavouritesManager ilObject2GUI::$favourites
protected

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

◆ $html

string ilObject2GUI::$html
protected

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

◆ $id_type

int ilObject2GUI::$id_type
protected

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

Referenced by ilObjFileServicesGUI\__construct(), __construct(), and getIdType().

◆ $lng

◆ $locator

◆ $node_id

◆ $obj_definition

ilObjectDefinition ilObject2GUI::$obj_definition
protected

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

◆ $object_id

int ilObject2GUI::$object_id
protected

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

Referenced by __construct().

◆ $parent_id

◆ $rbac_admin

ilRbacAdmin ilObject2GUI::$rbac_admin
protected

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

◆ $rbac_review

ilRbacReview ilObject2GUI::$rbac_review
protected

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

◆ $rbac_system

ilRbacSystem ilObject2GUI::$rbac_system
protected

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

◆ $refinery

Factory ilObject2GUI::$refinery
protected

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

◆ $request_ref_id

int ilObject2GUI::$request_ref_id
protected

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

◆ $retriever

ilObjectRequestRetriever ilObject2GUI::$retriever
private

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

◆ $tabs_gui

ilTabsGUI ilObject2GUI::$tabs_gui
protected

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

Referenced by ilObjExerciseVerificationGUI\create().

◆ $toolbar

◆ $tpl

◆ $type

◆ $user

◆ OBJECT_ID

const ilObject2GUI::OBJECT_ID = 0

◆ PORTFOLIO_OBJECT_ID

const ilObject2GUI::PORTFOLIO_OBJECT_ID = 5

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

Referenced by __construct(), assignObject(), confirmedDelete(), and delete().

◆ REPOSITORY_NODE_ID

◆ REPOSITORY_OBJECT_ID

const ilObject2GUI::REPOSITORY_OBJECT_ID = 3

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

Referenced by __construct(), assignObject(), confirmedDelete(), and delete().

◆ WORKSPACE_NODE_ID

◆ WORKSPACE_OBJECT_ID


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