ILIAS  trunk Revision v11.0_alpha-1731-gff9cd7e2bd3
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ilObjDataCollectionGUI Class Reference

ilObjDataCollectionGUI: ilInfoScreenGUI, ilNoteGUI, ilCommonActionDispatcherGUI ilObjDataCollectionGUI: ilPermissionGUI, ilObjectCopyGUI, ilDclExportGUI ilObjDataCollectionGUI: ilDclRecordListGUI, ilDclRecordEditGUI ilObjDataCollectionGUI: ilDclDetailedViewGUI ilObjDataCollectionGUI: ilDclTableListGUI, ilObjFileGUI ilObjDataCollectionGUI: ilObjUserGUI ilObjDataCollectionGUI: ilRatingGUI ilObjDataCollectionGUI: ilPropertyFormGUI ilObjDataCollectionGUI: ilDclPropertyFormGUI ilObjDataCollectionGUI: ilObjectMetaDataGUI ilObjDataCollectionGUI: ilObjectContentStyleSettingsGUI More...

+ Inheritance diagram for ilObjDataCollectionGUI:
+ Collaboration diagram for ilObjDataCollectionGUI:

Public Member Functions

 __construct (int $a_id=0, int $a_id_type=self::REPOSITORY_NODE_ID, int $a_parent_node_id=0)
 
 getObjectId ()
 
 getStandardCmd ()
 
 getType ()
 
 executeCommand ()
 
 infoScreen ()
 this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually, if everything works through ilCtrl in the future this may be changed More...
 
 render ()
 
 infoScreenForward ()
 show information screen More...
 
 edit ()
 
 update ()
 
 listRecords ()
 
 getDataCollectionObject ()
 
 toggleNotification ()
 
- Public Member Functions inherited from ilObject2GUI
 __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)
 
 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 _goto (string $a_target)
 
- Static Public Member Functions inherited from ilObject2GUI
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 GET_REF_ID = "ref_id"
 
const GET_TABLE_ID = "table_id"
 
const GET_VIEW_ID = "tableview_id"
 
const GET_RECORD_ID = "record_id"
 
const TAB_EDIT_DCL = 'settings'
 
const TAB_LIST_TABLES = 'dcl_tables'
 
const TAB_META_DATA = 'meta_data'
 
const TAB_EXPORT = 'export'
 
const TAB_LIST_PERMISSIONS = 'perm_settings'
 
const TAB_INFO = 'info_short'
 
const TAB_CONTENT = 'content'
 
ilObject $object = null
 
- Data Fields inherited from ilObject2GUI
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

 handleExport (bool $do_default=false)
 
 handleExportAsync ()
 
 getTableViewId ()
 
 addLocatorItems ()
 
 afterSave (ilObject $new_object)
 
 setTabs ()
 setTabs create tabs (repository/workspace switch) this had to be moved here because of the context-specific permission tab More...
 
 initForm ()
 
 setEditTabs ()
 
 getEditFormCustomValues (array &$a_values)
 
 updateCustom (ilPropertyFormGUI $form)
 
 addHeaderAction ()
 
- Protected Member Functions inherited from ilObject2GUI
 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="")
 
 setTargetFrame (string $cmd, string $target_frame)
 
 getCenterColumnHTML ()
 
 getRightColumnHTML ()
 
 checkPermission (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 showPossibleSubObjects ()
 
 redirectToRefId (int $ref_id, string $cmd="")
 
 addAdminLocatorItems (bool $do_not_add_object=false)
 
 setTabs ()
 create tabs (repository/workspace switch) More...
 
 getReturnLocation (string $cmd, string $location="")
 Deprecated functions. More...
 
 setReturnLocation (string $cmd, string $location)
 
 showActions ()
 
 getTabs ()
 
 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 ()
 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

ilCtrl $ctrl
 
ilLanguage $lng
 
ILIAS HTTP Services $http
 
ilTabsGUI $tabs
 
int $table_id
 
- Protected Attributes inherited from ilObject2GUI
ilObjectDefinition $obj_definition
 
ilGlobalTemplateInterface $tpl
 
ilCtrl $ctrl
 
ilLanguage $lng
 
ilTabsGUI $tabs_gui
 
ilFavouritesManager $favourites
 
ilErrorHandling $error
 
ilLocatorGUI $locator
 
ilObjUser $user
 
ilAccessHandler $access
 
ilToolbarGUI $toolbar
 
ArrayBasedRequestWrapper $post_wrapper
 
RequestWrapper $request_wrapper
 
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
 
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
 
ilObjectCustomIconFactory $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 Member Functions

 setTableId (int $objectOrRefId=0)
 
 addJavaScript ()
 
 addTab (string $langKey, string $link)
 
 emptyInfo ()
 

Private Attributes

ILIAS Notes Service $notes
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilObjDataCollectionGUI::__construct ( int  $a_id = 0,
int  $a_id_type = self::REPOSITORY_NODE_ID,
int  $a_parent_node_id = 0 
)

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

References $DIC, ILIAS\GlobalScreen\Provider\__construct(), addJavaScript(), ILIAS\Repository\ctrl(), ilObjectGUI\getRefId(), ILIAS\FileDelivery\http(), ILIAS\Repository\lng(), setTableId(), and ILIAS\Repository\tabs().

63  {
64  global $DIC;
65 
66  parent::__construct($a_id, $a_id_type, $a_parent_node_id);
67 
68  $this->http = $DIC->http();
69  $this->tabs = $DIC->tabs();
70  $this->notes = $DIC->notes();
71 
72  $this->lng->loadLanguageModule("dcl");
73  $this->lng->loadLanguageModule('content');
74  $this->lng->loadLanguageModule('obj');
75  $this->lng->loadLanguageModule('cntr');
76 
77  $this->setTableId($this->getRefId());
78 
79  if ($this->ctrl->isAsynch() === false) {
80  $this->addJavaScript();
81  }
82 
83  $this->ctrl->saveParameter($this, "table_id");
84  }
static http()
Fetches the global http state from ILIAS.
global $DIC
Definition: shib_login.php:22
__construct(Container $dic, ilPlugin $plugin)
+ Here is the call graph for this function:

Member Function Documentation

◆ _goto()

static ilObjDataCollectionGUI::_goto ( string  $a_target)
static

Definition at line 362 of file class.ilObjDataCollectionGUI.php.

References ilObject2GUI\$access, $DIC, $message, ilObjectGUI\$ref_id, ilObject2GUI\$tpl, ilObjectGUI\_gotoRepositoryNode(), ilObjectGUI\_gotoRepositoryRoot(), ilObject\_lookupObjId(), ilObject\_lookupTitle(), ilRBACAccessHandler\checkAccess(), ILIAS\Repository\int(), null, ILIAS\UICore\GlobalTemplate\setOnScreenMessage(), and ilLanguage\txt().

362  : void
363  {
364  global $DIC;
365  $lng = $DIC->language();
366 
367  $ilCtrl = $DIC->ctrl();
368  $access = $DIC->access();
369  $tpl = $DIC->ui()->mainTemplate();
370 
371  $values = [self::GET_REF_ID, self::GET_TABLE_ID, self::GET_VIEW_ID, self::GET_RECORD_ID];
372  $values = array_combine($values, array_pad(explode("_", $a_target), count($values), null));
373 
374  $ref_id = (int) $values[self::GET_REF_ID];
375 
376  //load record list
377  if ($access->checkAccess('read', "", $ref_id)) {
378  $ilCtrl->setParameterByClass(ilRepositoryGUI::class, self::GET_REF_ID, $ref_id);
379  if ($values['table_id'] !== null) {
380  $ilCtrl->setParameterByClass(ilObjDataCollectionGUI::class, self::GET_TABLE_ID, $values['table_id']);
381  if ($values['tableview_id'] !== null) {
382  $ilCtrl->setParameterByClass(ilObjDataCollectionGUI::class, self::GET_VIEW_ID, $values['tableview_id']);
383  }
384  if ($values['record_id'] !== null) {
385  $ilCtrl->setParameterByClass(ilDclDetailedViewGUI::class, self::GET_RECORD_ID, $values['record_id']);
386  $ilCtrl->redirectByClass([ilRepositoryGUI::class, self::class, ilDclDetailedViewGUI::class], "renderRecord");
387  }
388  }
389  $ilCtrl->redirectByClass([ilRepositoryGUI::class, self::class, ilDclRecordListGUI::class], "listRecords");
390  }
391  //redirect to info screen
392  elseif ($access->checkAccess('visbile', "", $ref_id)) {
393  ilObjectGUI::_gotoRepositoryNode((int) $a_target, "infoScreen");
394  }
395  //redirect if no permission given
396  else {
397  $message = sprintf(
398  $lng->txt("msg_no_perm_read_item"),
400  );
401  $tpl->setOnScreenMessage('failure', $message, true);
402 
404  }
405  }
setOnScreenMessage(string $type, string $a_txt, bool $a_keep=false)
Set a message to be displayed to the user.
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
checkAccess(string $a_permission, string $a_cmd, int $a_ref_id, string $a_type="", ?int $a_obj_id=null, ?int $a_tree_id=null)
check access for an object (provide $a_type and $a_obj_id if available for better performance) ...
static _gotoRepositoryNode(int $ref_id, string $cmd="")
static _lookupObjId(int $ref_id)
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
static _lookupTitle(int $obj_id)
global $DIC
Definition: shib_login.php:22
ilGlobalTemplateInterface $tpl
$message
Definition: xapiexit.php:31
static _gotoRepositoryRoot(bool $raise_error=false)
Goto repository root.
ilAccessHandler $access
+ Here is the call graph for this function:

◆ addHeaderAction()

ilObjDataCollectionGUI::addHeaderAction ( )
protected

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

References ilObjectGUI\$obj_id, ILIAS\Repository\access(), ANONYMOUS_USER_ID, ILIAS\Repository\ctrl(), ilUtil\getImagePath(), ilNotification\hasNotification(), ILIAS\Repository\lng(), ilObjectListGUI\prepareJsLinks(), ilNotification\TYPE_DATA_COLLECTION, ilCommonActionDispatcherGUI\TYPE_REPOSITORY, and ILIAS\Repository\user().

Referenced by executeCommand().

626  : void
627  {
629  $this->ctrl->getLinkTarget($this, "redrawHeaderAction", "", true),
630  "",
631  $this->ctrl->getLinkTargetByClass([ilCommonActionDispatcherGUI::class, ilTaggingGUI::class], "", "", true)
632  );
633 
634  $dispatcher = new ilCommonActionDispatcherGUI(ilCommonActionDispatcherGUI::TYPE_REPOSITORY, $this->access, "dcl", $this->ref_id, $this->obj_id);
635 
636  $lg = $dispatcher->initHeaderAction();
637 
638  // notification
639  if ($this->user->getId() != ANONYMOUS_USER_ID and $this->object->getNotification() == 1) {
641  //Command Activate Notification
642  $this->ctrl->setParameter($this, "ntf", 1);
643  $lg->addCustomCommand($this->ctrl->getLinkTarget($this, "toggleNotification"), "dcl_notification_deactivate_dcl");
644 
645  $lg->addHeaderIcon("not_icon", ilUtil::getImagePath("object/notification_on.svg"), $this->lng->txt("dcl_notification_activated"));
646  } else {
647  //Command Deactivate Notification
648  $this->ctrl->setParameter($this, "ntf", 2);
649  $lg->addCustomCommand($this->ctrl->getLinkTarget($this, "toggleNotification"), "dcl_notification_activate_dcl");
650 
651  $lg->addHeaderIcon("not_icon", ilUtil::getImagePath("object/notification_off.svg"), $this->lng->txt("dcl_notification_deactivated"));
652  }
653  $this->ctrl->setParameter($this, "ntf", "");
654  }
655 
656  $this->tpl->setHeaderActionMenu($lg->getHeaderAction());
657  }
const ANONYMOUS_USER_ID
Definition: constants.php:27
static getImagePath(string $image_name, string $module_path="", string $mode="output", bool $offline=false)
get image path (for images located in a template directory)
static prepareJsLinks(string $redraw_url, string $notes_url, string $tags_url, ?ilGlobalTemplateInterface $tpl=null)
Insert js/ajax links into template.
static hasNotification(int $type, int $user_id, int $id)
Check notification status for object and user.
Class ilCommonActionDispatcherGUI.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addJavaScript()

ilObjDataCollectionGUI::addJavaScript ( )
private

Definition at line 104 of file class.ilObjDataCollectionGUI.php.

Referenced by __construct().

104  : void
105  {
106  $this->tpl->addJavaScript("assets/js/datacollection.js");
107  }
+ Here is the caller graph for this function:

◆ addLocatorItems()

ilObjDataCollectionGUI::addLocatorItems ( )
protected

Definition at line 351 of file class.ilObjDataCollectionGUI.php.

References ILIAS\Repository\ctrl(), ILIAS\Repository\locator(), and ILIAS\Repository\object().

351  : void
352  {
353  if (is_object($this->object) === true) {
354  $this->locator->addItem(
355  $this->object->getTitle(),
356  $this->ctrl->getLinkTarget($this, ""),
357  (string) $this->object->getRefId()
358  );
359  }
360  }
+ Here is the call graph for this function:

◆ addTab()

ilObjDataCollectionGUI::addTab ( string  $langKey,
string  $link 
)
private

Definition at line 463 of file class.ilObjDataCollectionGUI.php.

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

Referenced by setTabs().

463  : void
464  {
465  $this->tabs->addTab($langKey, $this->lng->txt($langKey), $link);
466  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ afterSave()

ilObjDataCollectionGUI::afterSave ( ilObject  $new_object)
protected

Definition at line 407 of file class.ilObjDataCollectionGUI.php.

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

407  : void
408  {
409  $this->tpl->setOnScreenMessage('success', $this->lng->txt("object_added"), true);
410  $this->ctrl->redirectByClass(ilDclTableListGUI::class, "listTables");
411  }
+ Here is the call graph for this function:

◆ edit()

ilObjDataCollectionGUI::edit ( )

Definition at line 505 of file class.ilObjDataCollectionGUI.php.

References ilObject2GUI\checkPermissionBool(), ILIAS\Repository\lng(), setEditTabs(), and ILIAS\Repository\tabs().

505  : void
506  {
507  if (!$this->checkPermissionBool('write')) {
508  $this->tpl->setOnScreenMessage($this->tpl::MESSAGE_TYPE_FAILURE, $this->lng->txt('permission_denied'));
509  }
510 
511  $this->setEditTabs();
512  $this->tabs->activateTab(self::TAB_EDIT_DCL);
513 
514  $this->tpl->setContent($this->ui_renderer->render($this->initForm()));
515  }
checkPermissionBool(string $perm, string $cmd="", string $type="", ?int $node_id=null)
+ Here is the call graph for this function:

◆ emptyInfo()

ilObjDataCollectionGUI::emptyInfo ( )
private

Definition at line 590 of file class.ilObjDataCollectionGUI.php.

References $DIC, ilDclCache\getTableCache(), ILIAS\Repository\object(), and ilLanguage\txt().

Referenced by updateCustom().

590  : void
591  {
592  global $DIC;
593  $lng = $DIC['lng'];
594  $table = ilDclCache::getTableCache($this->object->getFirstVisibleTableId());
595  $tables = $this->object->getTables();
596  if (count($tables) === 1 && count($table->getRecordFields()) === 0 && count($table->getRecords()) === 0
597  && $this->object->getOnline()
598  ) {
599  $this->tpl->setOnScreenMessage('info', $lng->txt("dcl_no_content_warning"), true);
600  }
601  }
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
global $DIC
Definition: shib_login.php:22
static getTableCache(?int $table_id=null)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ executeCommand()

ilObjDataCollectionGUI::executeCommand ( )
Exceptions
ilCtrlException

Definition at line 122 of file class.ilObjDataCollectionGUI.php.

References $DIC, addHeaderAction(), ilObject2GUI\checkPermission(), ilObject2GUI\checkPermissionBool(), ilDclRecordListGUI\CMD_LIST_RECORDS, ILIAS\Repository\ctrl(), ilObject2GUI\getCreationMode(), ilCommonActionDispatcherGUI\getInstanceFromAjaxCall(), ilObjectGUI\getObject(), ilObjectGUI\getRefId(), getTableViewId(), handleExport(), ILIAS\FileDelivery\http(), infoScreenForward(), listRecords(), ILIAS\Repository\lng(), null, ILIAS\Repository\object(), ilObject2GUI\prepareOutput(), ILIAS\Repository\refinery(), setEditTabs(), and ILIAS\Repository\tabs().

122  : void
123  {
124  global $DIC;
125 
126  $ilNavigationHistory = $DIC['ilNavigationHistory'];
127  $DIC->help()->setScreenIdComponent('dcl');
128 
129  // Navigation History
130  $link = $this->ctrl->getLinkTarget($this, "render");
131 
132  if ($this->getObject() !== null) {
133  $ilNavigationHistory->addItem($this->object->getRefId(), $link, "dcl");
134  }
135 
136  $next_class = $this->ctrl->getNextClass($this);
137  $cmd = $this->ctrl->getCmd();
138 
139  if (!$this->getCreationMode() && $next_class != "ilinfoscreengui" && $cmd != 'infoScreen' && !$this->checkPermissionBool("read")) {
140  $DIC->ui()->mainTemplate()->loadStandardTemplate();
141  $DIC->ui()->mainTemplate()->setContent("Permission Denied.");
142 
143  return;
144  }
145 
146  switch ($next_class) {
147  case strtolower(ilInfoScreenGUI::class):
148  $this->prepareOutput();
149  $this->tabs->activateTab(self::TAB_INFO);
150  $this->infoScreenForward();
151  break;
152 
153  case strtolower(ilCommonActionDispatcherGUI::class):
154  $this->prepareOutput();
156  $gui->enableCommentsSettings(false);
157  $this->ctrl->forwardCommand($gui);
158  break;
159 
160  case strtolower(ilPermissionGUI::class):
161  $this->prepareOutput();
162  $this->tabs->activateTab(self::TAB_LIST_PERMISSIONS);
163  $perm_gui = new ilPermissionGUI($this);
164  $this->ctrl->forwardCommand($perm_gui);
165  break;
166 
167  case strtolower(ilObjectCopyGUI::class):
168  $cp = new ilObjectCopyGUI($this);
169  $cp->setType("dcl");
170  $DIC->ui()->mainTemplate()->loadStandardTemplate();
171  $this->ctrl->forwardCommand($cp);
172  break;
173 
174  case strtolower(ilDclTableListGUI::class):
175  $this->prepareOutput();
176  $this->tabs->activateTab(self::TAB_LIST_TABLES);
177  $tablelist_gui = new ilDclTableListGUI($this);
178  $this->ctrl->forwardCommand($tablelist_gui);
179  break;
180 
181  case strtolower(ilDclRecordListGUI::class):
182  $this->addHeaderAction();
183  $this->prepareOutput();
184  $this->tabs->activateTab(self::TAB_CONTENT);
185  $recordlist_gui = new ilDclRecordListGUI($this, $this->table_id, $this->getTableViewId());
186  $this->ctrl->forwardCommand($recordlist_gui);
187  break;
188 
189  case strtolower(ilDclRecordEditGUI::class):
190  $this->prepareOutput();
191  $this->tabs->activateTab(self::TAB_CONTENT);
192  $recordedit_gui = new ilDclRecordEditGUI($this, $this->table_id, $this->getTableViewId());
193  $this->ctrl->forwardCommand($recordedit_gui);
194  break;
195 
196  case strtolower(ilObjFileGUI::class):
197  $this->prepareOutput();
198  $this->tabs->activateTab(self::TAB_CONTENT);
199  $file_gui = new ilObjFile($this->getRefId());
200  $this->ctrl->forwardCommand($file_gui);
201  break;
202 
203  case strtolower(ilRatingGUI::class):
204  $rgui = new ilRatingGUI();
205 
206  $record_id = $this->http->wrapper()->query()->retrieve('record_id', $this->refinery->kindlyTo()->int());
207  $field_id = $this->http->wrapper()->query()->retrieve('field_id', $this->refinery->kindlyTo()->int());
208 
209  $rgui->setObject($record_id, "dcl_record", $field_id, "dcl_field");
210  $rgui->executeCommand();
211  $this->listRecords();
212  break;
213 
214  case strtolower(ilDclDetailedViewGUI::class):
215  $this->prepareOutput();
216  $recordview_gui = new ilDclDetailedViewGUI($this, $this->getTableViewId());
217  $this->ctrl->forwardCommand($recordview_gui);
218  $this->tabs->setBackTarget(
219  $this->lng->txt("back"),
220  $this->ctrl->getLinkTargetByClass(
221  ilDclRecordListGUI::class,
223  )
224  );
225  break;
226 
227  case strtolower(ilNoteGUI::class):
228  $this->prepareOutput();
229  $recordviewGui = new ilDclDetailedViewGUI($this, $this->getTableViewId());
230  $this->ctrl->forwardCommand($recordviewGui);
231  $this->tabs->clearTargets();
232  $this->tabs->setBackTarget($this->lng->txt("back"), $this->ctrl->getLinkTarget($this, ""));
233  break;
234  case strtolower(ilDclExportGUI::class):
235  $this->prepareOutput();
236  $this->handleExport();
237  break;
238 
239  case strtolower(ilDclPropertyFormGUI::class):
240  $recordedit_gui = new ilDclRecordEditGUI($this, $this->table_id, $this->getTableViewId());
241  $recordedit_gui->getRecord();
242  $recordedit_gui->initForm();
243  $form = $recordedit_gui->getForm();
244  $this->ctrl->forwardCommand($form);
245  break;
246 
247  case strtolower(ilObjectMetaDataGUI::class):
248  $this->checkPermission('write');
249  $this->prepareOutput();
250  $this->tabs->activateTab(self::TAB_META_DATA);
251  $gui = new ilObjectMetaDataGUI($this->object);
252  $this->ctrl->forwardCommand($gui);
253  break;
254 
255  case strtolower(ilObjectContentStyleSettingsGUI::class):
256  $this->prepareOutput();
257  $this->setEditTabs();
258  $this->tabs->activateTab('settings');
259  $this->tabs->activateSubTab('cont_style');
260  global $DIC;
261  $settings_gui = $DIC->contentStyle()->gui()->objectSettingsGUIForRefId(null, $this->ref_id);
262  $this->ctrl->forwardCommand($settings_gui);
263  break;
264 
265  default:
266  parent::executeCommand();
267  }
268  }
handleExport(bool $do_default=false)
Class ilObjectMetaDataGUI.
GUI class for the workflow of copying objects.
prepareOutput(bool $show_sub_objects=true)
ilDclTableListGUI: ilDclFieldListGUI, ilDclFieldEditGUI, ilDclTableViewGUI, ilDclTableEditGUI ...
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
static http()
Fetches the global http state from ILIAS.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
checkPermissionBool(string $perm, string $cmd="", string $type="", ?int $node_id=null)
Class ilObjFile.
global $DIC
Definition: shib_login.php:22
checkPermission(string $perm, string $cmd="", string $type="", ?int $ref_id=null)
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
infoScreenForward()
show information screen
ilDclDetailedViewGUI: ilDclDetailedViewDefinitionGUI, ilEditClipboardGUI, ilCommentGUI ...
+ Here is the call graph for this function:

◆ getDataCollectionObject()

ilObjDataCollectionGUI::getDataCollectionObject ( )

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

564  {
565  return new ilObjDataCollection($this->ref_id, true);
566  }

◆ getEditFormCustomValues()

ilObjDataCollectionGUI::getEditFormCustomValues ( array &  $a_values)
protected

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

568  : void
569  {
570  $a_values["is_online"] = $this->object->getOnline();
571  $a_values["rating"] = $this->object->getRating();
572  $a_values["public_notes"] = $this->object->getPublicNotes();
573  $a_values["approval"] = $this->object->getApproval();
574  $a_values["notification"] = $this->object->getNotification();
575  }

◆ getObjectId()

ilObjDataCollectionGUI::getObjectId ( )

Definition at line 99 of file class.ilObjDataCollectionGUI.php.

References ilObjectGUI\$obj_id.

99  : int
100  {
101  return $this->obj_id;
102  }

◆ getStandardCmd()

ilObjDataCollectionGUI::getStandardCmd ( )

Definition at line 109 of file class.ilObjDataCollectionGUI.php.

109  : string
110  {
111  return "render";
112  }

◆ getTableViewId()

ilObjDataCollectionGUI::getTableViewId ( )
protected

Definition at line 290 of file class.ilObjDataCollectionGUI.php.

References ilObjectGUI\getRefId(), ilDclCache\getTableCache(), ILIAS\FileDelivery\http(), null, and ILIAS\Repository\refinery().

Referenced by executeCommand().

290  : int
291  {
292  $tableview_id = null;
293  if ($this->http->wrapper()->query()->has('tableview_id')) {
294  $tableview_id = $this->http->wrapper()->query()->retrieve(
295  'tableview_id',
296  $this->refinery->kindlyTo()->int()
297  );
298  }
299  if ($this->http->wrapper()->post()->has('tableview_id')) {
300  $tableview_id = $this->http->wrapper()->post()->retrieve(
301  'tableview_id',
302  $this->refinery->kindlyTo()->int()
303  );
304  }
305  if (!$tableview_id) {
306  $table_obj = ilDclCache::getTableCache($this->table_id);
307  $tableview_id = $table_obj->getFirstTableViewId($this->getRefId());
308  }
309  if ($tableview_id === null) {
310  throw new InvalidArgumentException('No visible tableview configured!');
311  }
312  return $tableview_id;
313  }
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
static http()
Fetches the global http state from ILIAS.
static getTableCache(?int $table_id=null)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getType()

ilObjDataCollectionGUI::getType ( )

Definition at line 114 of file class.ilObjDataCollectionGUI.php.

114  : string
115  {
116  return "dcl";
117  }

◆ handleExport()

ilObjDataCollectionGUI::handleExport ( bool  $do_default = false)
protected

Definition at line 270 of file class.ilObjDataCollectionGUI.php.

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

Referenced by executeCommand().

270  : void
271  {
272  $this->tabs->setTabActive(self::TAB_EXPORT);
273  $exp_gui = new ilDclExportGUI($this);
274  if ($do_default) {
275  $exp_gui->listExportFiles();
276  } else {
277  $this->ctrl->forwardCommand($exp_gui);
278  }
279  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ handleExportAsync()

ilObjDataCollectionGUI::handleExportAsync ( )
protected

Definition at line 281 of file class.ilObjDataCollectionGUI.php.

References $table_id, ILIAS\Repository\ctrl(), ilDclContentExporter\exportAsync(), ILIAS\Repository\object(), and ILIAS\Repository\tabs().

281  : void
282  {
283  $this->tabs->setTabActive(self::TAB_EXPORT);
284  $exp_gui = new ilDclExportGUI($this);
285  $exporter = new ilDclContentExporter($this->object->getRefId(), $this->table_id);
286  $exporter->exportAsync();
287  $this->ctrl->redirect($exp_gui);
288  }
exportAsync(string $format=self::EXPORT_EXCEL, ?string $filepath=null)
Hook-Class for exporting data-collections (used in SOAP-Class) This Class avoids duplicated code by r...
+ Here is the call graph for this function:

◆ infoScreen()

ilObjDataCollectionGUI::infoScreen ( )

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

Definition at line 320 of file class.ilObjDataCollectionGUI.php.

References infoScreenForward().

320  : void
321  {
322  // @todo: removed deprecated ilCtrl methods, this needs inspection by a maintainer.
323  // $this->ctrl->setCmd("showSummary");
324  // $this->ctrl->setCmdClass(ilInfoScreenGUI::class);
325  $this->infoScreenForward();
326  }
infoScreenForward()
show information screen
+ Here is the call graph for this function:

◆ infoScreenForward()

ilObjDataCollectionGUI::infoScreenForward ( )

show information screen

Definition at line 336 of file class.ilObjDataCollectionGUI.php.

References ilObject2GUI\checkPermission(), ilObject2GUI\checkPermissionBool(), ILIAS\Repository\ctrl(), ILIAS\Repository\object(), and ILIAS\Repository\tabs().

Referenced by executeCommand(), and infoScreen().

336  : void
337  {
338  $this->tabs->activateTab(self::TAB_INFO);
339 
340  if (!$this->checkPermissionBool('visible')) {
341  $this->checkPermission('read');
342  }
343 
344  $info = new ilInfoScreenGUI($this);
345  $info->enablePrivateNotes();
346  $info->addMetaDataSections($this->object->getId(), 0, $this->object->getType());
347 
348  $this->ctrl->forwardCommand($info);
349  }
checkPermissionBool(string $perm, string $cmd="", string $type="", ?int $node_id=null)
checkPermission(string $perm, string $cmd="", string $type="", ?int $ref_id=null)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initForm()

ilObjDataCollectionGUI::initForm ( )
protected

Definition at line 468 of file class.ilObjDataCollectionGUI.php.

References ILIAS\UI\Implementation\Component\Input\$inputs, ilObject2GUI\$refinery, ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), ILIAS\Repository\object(), and ILIAS\UI\Implementation\Component\Input\withValue().

Referenced by update().

468  : Form
469  {
470  $inputs = [];
471 
472  $edit = [];
473  $edit['title'] = $this->ui_factory->input()->field()->text($this->lng->txt('title'))->withRequired(true);
474  $edit['description'] = $this->ui_factory->input()->field()->textarea($this->lng->txt('description'));
475  $edit['notification'] = $this->ui_factory->input()->field()->checkbox(
476  $this->lng->txt('dcl_activate_notification'),
477  $this->lng->txt('dcl_notification_info')
478  );
479  $inputs['edit'] = $this->ui_factory->input()->field()->section($edit, $this->lng->txt($this->type . '_edit'))
480  ->withValue([
481  'title' => $this->object->getTitle(),
482  'description' => $this->object->getLongDescription(),
483  'notification' => $this->object->getNotification(),
484  ]);
485 
486  $availability = [];
487  $availability['online'] = $this->ui_factory->input()->field()->checkbox(
488  $this->lng->txt('online'),
489  $this->lng->txt('dcl_online_info')
490  );
491  $inputs['availability'] = $this->ui_factory->input()->field()->section($availability, $this->lng->txt('obj_activation_list_gui'))
492  ->withValue(['online' => $this->object->getOnline(),]);
493 
494  $presentation = [];
495  $presentation['tile_image'] = $this->object->getObjectProperties()->getPropertyTileImage()->toForm(
496  $this->lng,
497  $this->ui_factory->input()->field(),
499  );
500  $inputs['presentation'] = $this->ui_factory->input()->field()->section($presentation, $this->lng->txt('cont_presentation'));
501 
502  return $this->ui_factory->input()->container()->form()->standard($this->ctrl->getFormAction($this, 'update'), $inputs);
503  }
This describes commonalities between all forms.
Definition: Form.php:32
withValue($value)
Get an input like this with another value displayed on the client side.
Definition: Group.php:61
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ listRecords()

ilObjDataCollectionGUI::listRecords ( )
final

Definition at line 558 of file class.ilObjDataCollectionGUI.php.

References ILIAS\Repository\ctrl().

Referenced by executeCommand(), and render().

558  : void
559  {
560  $this->ctrl->redirectByClass(ilDclRecordListGUI::class, "show");
561  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ render()

ilObjDataCollectionGUI::render ( )

Definition at line 328 of file class.ilObjDataCollectionGUI.php.

References listRecords().

328  : void
329  {
330  $this->listRecords();
331  }
+ Here is the call graph for this function:

◆ setEditTabs()

ilObjDataCollectionGUI::setEditTabs ( )
protected

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

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

Referenced by edit(), executeCommand(), and update().

542  : void
543  {
544  $this->tabs->addSubTab(
545  'general',
546  $this->lng->txt('general'),
547  $this->ctrl->getLinkTargetByClass(self::class, 'edit')
548  );
549  $this->tabs->addSubTab(
550  'cont_style',
551  $this->lng->txt('cont_style'),
552  $this->ctrl->getLinkTargetByClass(ilObjectContentStyleSettingsGUI::class)
553  );
554 
555  $this->tabs->activateSubTab('general');
556  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setTableId()

ilObjDataCollectionGUI::setTableId ( int  $objectOrRefId = 0)
private

Definition at line 86 of file class.ilObjDataCollectionGUI.php.

References ILIAS\FileDelivery\http(), and ILIAS\Repository\refinery().

Referenced by __construct().

86  : void
87  {
88  if ($this->http->wrapper()->query()->has('table_id')) {
89  $this->table_id = $this->http->wrapper()->query()->retrieve('table_id', $this->refinery->kindlyTo()->int());
90  } elseif ($this->http->wrapper()->query()->has('tableview_id')) {
91  $this->table_id = ilDclTableView::find(
92  $this->http->wrapper()->query()->retrieve('tableview_id', $this->refinery->kindlyTo()->int())
93  )->getTableId();
94  } elseif ($objectOrRefId > 0) {
95  $this->table_id = $this->object->getFirstVisibleTableId();
96  }
97  }
static http()
Fetches the global http state from ILIAS.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setTabs()

ilObjDataCollectionGUI::setTabs ( )
protected

setTabs create tabs (repository/workspace switch) this had to be moved here because of the context-specific permission tab

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

References ilObjectGUI\$ref_id, ILIAS\Repository\access(), addTab(), ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

418  : void
419  {
420  $ref_id = $this->object->getRefId();
421 
422  // read permission
423  if ($this->access->checkAccess('read', "", $ref_id) === true) {
424  // list records
425  $this->addTab(self::TAB_CONTENT, $this->ctrl->getLinkTargetByClass(ilDclRecordListGUI::class, "show"));
426  }
427 
428  // visible or read permission
429  if ($this->access->checkAccess('visible', "", $ref_id) === true
430  || $this->access->checkAccess('read', "", $ref_id) === true) {
431  // info screen
432  $this->addTab(self::TAB_INFO, $this->ctrl->getLinkTargetByClass(
433  ilInfoScreenGUI::class,
434  "showSummary"
435  ));
436  }
437 
438  // write permission
439  if ($this->access->checkAccess('write', "", $ref_id) === true) {
440  // settings
441  $this->addTab(self::TAB_EDIT_DCL, $this->ctrl->getLinkTarget($this, 'edit'));
442  // list tables
443  $this->addTab(self::TAB_LIST_TABLES, $this->ctrl->getLinkTargetByClass(ilDclTableListGUI::class, "listTables"));
444  // metadata
445  $mdgui = new ilObjectMetaDataGUI($this->object);
446  if ($mdtab = $mdgui->getTab()) {
447  $this->tabs_gui->addTab(self::TAB_META_DATA, $this->lng->txt('meta_data'), $mdtab);
448  }
449  // export
450  $this->addTab(self::TAB_EXPORT, $this->ctrl->getLinkTargetByClass(ilDclExportGUI::class, ""));
451  }
452 
453  // edit permissions
454  if ($this->access->checkAccess('edit_permission', "", $ref_id) === true) {
455  //list permissions
456  $this->addTab(self::TAB_LIST_PERMISSIONS, $this->ctrl->getLinkTargetByClass(
457  ilPermissionGUI::class,
458  "perm"
459  ));
460  }
461  }
Class ilObjectMetaDataGUI.
addTab(string $langKey, string $link)
+ Here is the call graph for this function:

◆ toggleNotification()

ilObjDataCollectionGUI::toggleNotification ( )
final

Definition at line 603 of file class.ilObjDataCollectionGUI.php.

References ilObjectGUI\$obj_id, ILIAS\Repository\ctrl(), ILIAS\FileDelivery\http(), ILIAS\Repository\refinery(), ilNotification\setNotification(), ilNotification\TYPE_DATA_COLLECTION, and ILIAS\Repository\user().

603  : void
604  {
605  $ntf = $this->http->wrapper()->query()->retrieve('ntf', $this->refinery->kindlyTo()->int());
606  switch ($ntf) {
607  case 1:
610  $this->user->getId(),
612  false
613  );
614  break;
615  case 2:
618  $this->user->getId(),
620  );
621  break;
622  }
623  $this->ctrl->redirectByClass(ilDclRecordListGUI::class, "show");
624  }
static http()
Fetches the global http state from ILIAS.
static setNotification(int $type, int $user_id, int $id, bool $status=true)
Set notification status for object and user.
+ Here is the call graph for this function:

◆ update()

ilObjDataCollectionGUI::update ( )

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

References ilObjectGUI\$data, ilObject2GUI\checkPermissionBool(), ILIAS\FileDelivery\http(), initForm(), ILIAS\Repository\lng(), null, setEditTabs(), and ILIAS\Repository\tabs().

517  : void
518  {
519  if (!$this->checkPermissionBool('write')) {
520  $this->error->raiseError($this->lng->txt('permission_denied'), $this->error->MESSAGE);
521  }
522 
523  $this->setEditTabs();
524  $this->tabs->activateTab(self::TAB_EDIT_DCL);
525 
526  $form = $this->initForm()->withRequest($this->http->request());
527  $data = $form->getData();
528 
529  if ($data !== null) {
530  $this->object->setTitle($data['edit']['title']);
531  $this->object->setDescription($data['edit']['description']);
532  $this->object->setNotification($data['edit']['notification']);
533  $this->object->setOnline($data['availability']['online']);
534  $this->object->getObjectProperties()->storePropertyTileImage($data['presentation']['tile_image']);
535  $this->object->update();
536  $this->tpl->setOnScreenMessage('success', $this->lng->txt('msg_obj_modified'), true);
537  }
538 
539  $this->tpl->setContent($this->ui_renderer->render($form));
540  }
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
static http()
Fetches the global http state from ILIAS.
checkPermissionBool(string $perm, string $cmd="", string $type="", ?int $node_id=null)
+ Here is the call graph for this function:

◆ updateCustom()

ilObjDataCollectionGUI::updateCustom ( ilPropertyFormGUI  $form)
protected

Definition at line 577 of file class.ilObjDataCollectionGUI.php.

References emptyInfo(), and ilPropertyFormGUI\getInput().

577  : void
578  {
579  $this->object->setOnline((bool) $form->getInput("is_online"));
580  $this->object->setRating((bool) $form->getInput("rating"));
581  $this->object->setPublicNotes((bool) $form->getInput("public_notes"));
582  $this->object->setApproval((bool) $form->getInput("approval"));
583  $this->object->setNotification((bool) $form->getInput("notification"));
584 
585  $this->object_service->commonSettings()->legacyForm($form, $this->object)->saveTileImage();
586 
587  $this->emptyInfo();
588  }
getInput(string $a_post_var, bool $ensureValidation=true)
Returns the input of an item, if item provides getInput method and as fallback the value of the HTTP-...
+ Here is the call graph for this function:

Field Documentation

◆ $ctrl

ilCtrl ilObjDataCollectionGUI::$ctrl
protected

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

◆ $http

ILIAS HTTP Services ilObjDataCollectionGUI::$http
protected

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

◆ $lng

ilLanguage ilObjDataCollectionGUI::$lng
protected

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

◆ $notes

ILIAS Notes Service ilObjDataCollectionGUI::$notes
private

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

◆ $object

ilObject ilObjDataCollectionGUI::$object = null

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

◆ $table_id

int ilObjDataCollectionGUI::$table_id
protected

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

Referenced by handleExportAsync().

◆ $tabs

ilTabsGUI ilObjDataCollectionGUI::$tabs
protected

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

◆ GET_RECORD_ID

const ilObjDataCollectionGUI::GET_RECORD_ID = "record_id"

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

◆ GET_REF_ID

const ilObjDataCollectionGUI::GET_REF_ID = "ref_id"

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

◆ GET_TABLE_ID

const ilObjDataCollectionGUI::GET_TABLE_ID = "table_id"

Definition at line 41 of file class.ilObjDataCollectionGUI.php.

◆ GET_VIEW_ID

const ilObjDataCollectionGUI::GET_VIEW_ID = "tableview_id"

Definition at line 42 of file class.ilObjDataCollectionGUI.php.

◆ TAB_CONTENT

const ilObjDataCollectionGUI::TAB_CONTENT = 'content'

Definition at line 51 of file class.ilObjDataCollectionGUI.php.

◆ TAB_EDIT_DCL

const ilObjDataCollectionGUI::TAB_EDIT_DCL = 'settings'

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

◆ TAB_EXPORT

const ilObjDataCollectionGUI::TAB_EXPORT = 'export'

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

◆ TAB_INFO

const ilObjDataCollectionGUI::TAB_INFO = 'info_short'

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

◆ TAB_LIST_PERMISSIONS

const ilObjDataCollectionGUI::TAB_LIST_PERMISSIONS = 'perm_settings'

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

◆ TAB_LIST_TABLES

const ilObjDataCollectionGUI::TAB_LIST_TABLES = 'dcl_tables'

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

◆ TAB_META_DATA

const ilObjDataCollectionGUI::TAB_META_DATA = 'meta_data'

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


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