ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilObjDataCollectionGUI Class Reference

Class ilObjDataCollectionGUI. More...

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

Public Member Functions

 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 ()
 show Content; redirect to ilDclRecordListGUI::listRecords More...
 
 infoScreenForward ()
 show information screen More...
 
 addLocatorItems ()
 Functions to be overwritten. More...
 
 setTabs ()
 setTabs create tabs (repository/workspace switch) More...
 
 listRecords ()
 called by goto More...
 
 getDataCollectionObject ()
 
 getEditFormCustomValues (array &$a_values)
 
 updateCustom (ilPropertyFormGUI $a_form)
 
 toggleNotification ()
 
 addHeaderAction ($a_redraw=false)
 
- Public Member Functions inherited from ilObject2GUI
 __construct ($a_id=0, $a_id_type=self::REPOSITORY_NODE_ID, $a_parent_node_id=0)
 Constructor. More...
 
 executeCommand ()
 execute command More...
 
 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 ($a_mode=true)
 if true, a creation screen is displayed the current $_GET[ref_id] don't belong to the current class! the mode is determined in ilrepositorygui More...
 
 getCreationMode ()
 get creation mode More...
 
 prepareOutput ($a_show_subobjects=true)
 prepare output More...
 
 isVisible ($a_ref_id, $a_type)
 
 trash ()
 
 undelete ()
 
 cancelDelete ()
 
 removeFromSystem ()
 
 cloneAll ()
 
 view ()
 view object content (repository/workspace switch) More...
 
 getType ()
 Functions that must be overwritten. More...
 
 create ()
 Deleted in ilObject. More...
 
 save ()
 
 edit ()
 
 update ()
 
 cancel ()
 
 importFile ()
 Import. More...
 
 putObjectInTree (ilObject $a_obj, $a_parent_node_id=null)
 Add object to tree at given position. More...
 
- Public Member Functions inherited from ilObjectGUI
 executeCommand ()
 execute command More...
 
 withReferences ()
 determines wether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode ($a_mode=true)
 if true, a creation screen is displayed the current $_GET[ref_id] don't belong to the current class! the mode is determined in ilrepositorygui More...
 
 getCreationMode ()
 get creation mode More...
 
 prepareOutput ($a_show_subobjects=true)
 prepare output More...
 
 getAdminTabs ()
 administration tabs show only permissions and trash folder More...
 
 getHTML ()
 
 confirmedDeleteObject ()
 confirmed deletion of object -> objects are moved to trash or deleted immediately, if trash is disabled More...
 
 cancelDeleteObject ()
 cancel deletion of object More...
 
 cancelObject ()
 cancel action and go back to previous page @access public More...
 
 createObject ()
 create new object form More...
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 save object More...
 
 getDidacticTemplateVar ($a_type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $a_obj, $a_parent_node_id=null)
 Add object to tree at given position. More...
 
 editObject ()
 edit object More...
 
 addExternalEditFormCustom (ilPropertyFormGUI $a_form)
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction ($a_cmd, $a_formaction="")
 get form action for command (command is method name without "Object", e.g. More...
 
 isVisible ($a_ref_id, $a_type)
 
 viewObject ()
 list childs of current object More...
 
 deleteObject ($a_error=false)
 Display deletion confirmation screen. More...
 
 cloneAllObject ()
 Clone single (not container object) Method is overwritten in ilContainerGUI. More...
 

Static Public Member Functions

static _goto ($a_target)
 
- Static Public Member Functions inherited from ilObject2GUI
static handleAfterSaveCallback (ilObject $a_obj, $a_callback_ref_id)
 After creation callback. More...
 
- Static Public Member Functions inherited from ilObjectGUI
static _gotoRepositoryRoot ($a_raise_error=false)
 Goto repository root. More...
 
static _gotoRepositoryNode ($a_ref_id, $a_cmd="frameset")
 Goto repository root. More...
 

Data Fields

const GET_DCL_GTR = "dcl_gtr"
 
const GET_REF_ID = "ref_id"
 
const GET_VIEW_ID = "tableview_id"
 
- Data Fields inherited from ilObject2GUI
 $tree
 
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 COPY_WIZARD_NEEDS_PAGE = 1
 
 $objDefinition
 
 $tpl
 
 $tree
 
 $lng
 
 $data
 
 $object
 
 $ref_id
 
 $obj_id
 
 $maxcount
 
 $formaction
 
 $return_location
 
 $target_frame
 
 $tab_target_script
 
 $actions
 
 $sub_objects
 
 $omit_locator = false
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 

Protected Member Functions

 initCreationForms ($a_new_type)
 
 afterSave (ilObject $a_new_object)
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 
- 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 ()
 Get access handler. More...
 
 setLocator ()
 set Locator More...
 
 deleteConfirmation ()
 Display delete confirmation form (workspace specific) More...
 
 deleteConfirmedObjects ()
 Delete objects (workspace specific) More...
 
 setTitleAndDescription ()
 called by prepare output More...
 
 showUpperIcon ()
 
 omitLocator ($a_omit=true)
 
 getTargetFrame ($a_cmd, $a_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame ($a_cmd, $a_target_frame)
 set specific target frame for command More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 May be overwritten in subclasses. More...
 
 checkPermission ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission and redirect on error. More...
 
 showPossibleSubObjects ()
 show possible subobjects (pulldown menu) More...
 
 redirectToRefId ($a_ref_id, $a_cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current $_GET["ref_id"] value More...
 
 fillCloneTemplate ($a_tpl_varname, $a_type)
 Fill object clone template This method can be called from any object GUI class that wants to offer object cloning. More...
 
 fillCloneSearchTemplate ($a_tpl_varname, $a_type)
 
 searchCloneSource ()
 
 buildCloneSelect ($existing_objs)
 
 addAdminLocatorItems ($a_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 ($a_cmd, $a_location="")
 Deprecated functions. More...
 
 setReturnLocation ($a_cmd, $a_location)
 set specific return location for command More...
 
 showActions ()
 
 getTabs ()
 get tabs abstract method. More...
 
 __showButton ($a_cmd, $a_text, $a_target='')
 
 hitsperpageObject ()
 
__initTableGUI ()
 
 __setTableGUIBasicData (&$tbl, &$result_set, $a_from="")
 standard implementation for tables use 'from' variable use different initial setting of table More...
 
 addLocatorItems ()
 Functions to be overwritten. More...
 
 initCreationForms ($a_new_type)
 Init creation froms. More...
 
 checkPermissionBool ($a_perm, $a_cmd="", $a_type="", $a_node_id=null)
 Check permission. More...
 
 initHeaderAction ($a_sub_type=null, $a_sub_id=null)
 Add header action menu. More...
 
 redrawHeaderAction ()
 Updating icons after ajax call. More...
 
 getPermanentLinkWidget ($a_append=null, $a_center=false)
 
 handleAutoRating (ilObject $a_new_obj)
 
- Protected Member Functions inherited from ilObjectGUI
 assignObject ()
 
 setTitleAndDescription ()
 called by prepare output More...
 
 initHeaderAction ($a_sub_type=null, $a_sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction ($a_list_gui)
 Insert header action into main template. More...
 
 addHeaderAction ()
 Add header action menu. More...
 
 redrawHeaderActionObject ()
 Ajax call: redraw action header only. More...
 
 showMountWebfolderIcon ()
 
 setTabs ()
 set admin tabs @access public More...
 
 setAdminTabs ()
 set admin tabs @access public More...
 
 setLocator ()
 set Locator More...
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator ($a_omit=true)
 
 addAdminLocatorItems ($a_do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 initCreationForms ($a_new_type)
 Init creation froms. More...
 
 getCreationFormsHTML (array $a_forms)
 Get HTML for creation forms (accordion) More...
 
 initCreateForm ($a_new_type)
 Init object creation form. More...
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 Show didactic template types. More...
 
 addDidacticTemplateOptions (array &$a_options)
 Add custom templates. More...
 
 afterSave (ilObject $a_new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 Init object edit form. More...
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 Get values for edit form. More...
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $a_form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $a_form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 initImportForm ($a_new_type)
 Init object import form. More...
 
 importFileObject ($parent_id=null, $a_catch_errors=true)
 Import. More...
 
 afterImport (ilObject $a_new_object)
 Post (successful) object import hook. More...
 
 setFormAction ($a_cmd, $a_formaction)
 set specific form action for command More...
 
 getReturnLocation ($a_cmd, $a_location="")
 get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation ($a_cmd, $a_location)
 set specific return location for command More...
 
 getTargetFrame ($a_cmd, $a_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame ($a_cmd, $a_target_frame)
 set specific target frame for command More...
 
 showPossibleSubObjects ()
 show possible subobjects (pulldown menu) More...
 
 getTemplateFile ($a_cmd, $a_type="")
 get a template blockfile format: tpl. More...
 
 getTabs ()
 get tabs abstract method. More...
 
 __showButton ($a_cmd, $a_text, $a_target='')
 
 hitsperpageObject ()
 
__initTableGUI ()
 
 __setTableGUIBasicData (&$tbl, &$result_set, $a_from="")
 standard implementation for tables use 'from' variable use different initial setting of table More...
 
 redirectToRefId ($a_ref_id, $a_cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current $_GET["ref_id"] value More...
 
 fillCloneTemplate ($a_tpl_varname, $a_type)
 Fill object clone template This method can be called from any object GUI class that wants to offer object cloning. More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 May be overwritten in subclasses. More...
 
 checkPermission ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission and redirect on error. More...
 
 checkPermissionBool ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission. More...
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 handleAutoRating (ilObject $a_new_obj)
 Activate rating automatically if parent container setting. More...
 

Private Member Functions

 emptyInfo ()
 

Additional Inherited Members

- Protected Attributes inherited from ilObject2GUI
 $object_id
 
 $node_id
 
 $creation_forms = array()
 
 $id_type = array()
 
 $parent_id
 
 $access_handler
 
- Protected Attributes inherited from ilObjectGUI
 $ilErr
 
 $locator
 
 $user
 
 $access
 
 $settings
 
 $rbacreview
 
 $toolbar
 
 $rbacsystem
 
 $tmp_import_dir
 
 $tabs_gui = null
 
 $ctrl
 

Detailed Description

Member Function Documentation

◆ _goto()

static ilObjDataCollectionGUI::_goto (   $a_target)
static
Parameters
$a_target

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

314 {
315 $id = explode("_", $a_target);
316
317 $_GET["baseClass"] = "ilRepositoryGUI";
318 $_GET[self::GET_REF_ID] = $id[0]; // ref_id
319 $_GET[self::GET_VIEW_ID] = $id[1]; // view_id
320 $_GET[self::GET_DCL_GTR] = $id[2]; // record_id
321 $_GET["cmd"] = "listRecords";
322 require_once('./ilias.php');
323 exit;
324 }
$_GET["client_id"]
if(!array_key_exists('StateId', $_REQUEST)) $id

References $_GET, $id, exit, GET_DCL_GTR, GET_REF_ID, and GET_VIEW_ID.

◆ addHeaderAction()

ilObjDataCollectionGUI::addHeaderAction (   $a_redraw = false)
Parameters
bool$a_redraw
Returns
string|void

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

519 {
520 global $DIC;
521 $ilUser = $DIC['ilUser'];
522 $ilAccess = $DIC['ilAccess'];
523 $tpl = $DIC['tpl'];
524 $lng = $DIC['lng'];
525 $ilCtrl = $DIC['ilCtrl'];
526
527 $dispatcher = new ilCommonActionDispatcherGUI(ilCommonActionDispatcherGUI::TYPE_REPOSITORY, $ilAccess, "dcl", $this->ref_id, $this->obj_id);
528
529 ilObjectListGUI::prepareJSLinks($this->ctrl->getLinkTarget($this, "redrawHeaderAction", "", true), $ilCtrl->getLinkTargetByClass(array(
530 "ilcommonactiondispatchergui",
531 "ilnotegui"
532 ), "", "", true, false), $ilCtrl->getLinkTargetByClass(array( "ilcommonactiondispatchergui", "iltagginggui" ), "", "", true, false));
533
534 $lg = $dispatcher->initHeaderAction();
535 //$lg->enableNotes(true);
536 //$lg->enableComments(ilObjWiki::_lookupPublicNotes($this->getPageObject()->getParentId()), false);
537
538 // notification
539 if ($ilUser->getId() != ANONYMOUS_USER_ID and $this->object->getNotification() == 1) {
541 //Command Activate Notification
542 $ilCtrl->setParameter($this, "ntf", 1);
543 $lg->addCustomCommand($ilCtrl->getLinkTarget($this, "toggleNotification"), "dcl_notification_deactivate_dcl");
544
545 $lg->addHeaderIcon("not_icon", ilUtil::getImagePath("notification_on.svg"), $lng->txt("dcl_notification_activated"));
546 } else {
547 //Command Deactivate Notification
548 $ilCtrl->setParameter($this, "ntf", 2);
549 $lg->addCustomCommand($ilCtrl->getLinkTarget($this, "toggleNotification"), "dcl_notification_activate_dcl");
550
551 $lg->addHeaderIcon("not_icon", ilUtil::getImagePath("notification_off.svg"), $lng->txt("dcl_notification_deactivated"));
552 }
553 $ilCtrl->setParameter($this, "ntf", "");
554 }
555
556 if (!$a_redraw) {
557 $tpl->setHeaderActionMenu($lg->getHeaderAction());
558 } else {
559 return $lg->getHeaderAction();
560 }
561
562 $tpl->setHeaderActionMenu($lg->getHeaderAction());
563 }
Class ilCommonActionDispatcherGUI.
static hasNotification($type, $user_id, $id)
Check notification status for object and user.
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
$lg
Definition: example_018.php:62
global $ilCtrl
Definition: ilias.php:18
global $DIC
Definition: saml.php:7
$ilUser
Definition: imgupload.php:18

References $DIC, $ilCtrl, $ilUser, $lg, ilObjectGUI\$lng, ilObjectGUI\$tpl, ilUtil\getImagePath(), ilNotification\hasNotification(), ilNotification\TYPE_DATA_COLLECTION, and ilCommonActionDispatcherGUI\TYPE_REPOSITORY.

+ Here is the call graph for this function:

◆ addLocatorItems()

ilObjDataCollectionGUI::addLocatorItems ( )

Functions to be overwritten.

Reimplemented from ilObject2GUI.

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

300 {
301 global $DIC;
302 $ilLocator = $DIC['ilLocator'];
303
304 if (is_object($this->object)) {
305 $ilLocator->addItem($this->object->getTitle(), $this->ctrl->getLinkTarget($this, ""), "", $this->node_id);
306 }
307 }

References $DIC.

◆ afterSave()

ilObjDataCollectionGUI::afterSave ( ilObject  $a_new_object)
protected
Parameters
ilObject$a_new_object

Reimplemented from ilObjectGUI.

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

344 {
345 ilUtil::sendSuccess($this->lng->txt("object_added"), true);
346 $this->ctrl->redirectByClass("ilDclTableListGUI", "listTables");
347 }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.

References ilUtil\sendSuccess().

+ Here is the call graph for this function:

◆ emptyInfo()

ilObjDataCollectionGUI::emptyInfo ( )
private

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

481 {
482 global $DIC;
483 $lng = $DIC['lng'];
484 $this->table = ilDclCache::getTableCache($this->object->getFirstVisibleTableId());
485 $tables = $this->object->getTables();
486 if (count($tables) == 1 and count($this->table->getRecordFields()) == 0 and count($this->table->getRecords()) == 0
487 and $this->object->getOnline()
488 ) {
489 ilUtil::sendInfo($lng->txt("dcl_no_content_warning"), true);
490 }
491 }
static getTableCache($table_id=0)
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.

References $DIC, ilObjectGUI\$lng, ilDclCache\getTableCache(), and ilUtil\sendInfo().

Referenced by updateCustom().

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

◆ executeCommand()

ilObjDataCollectionGUI::executeCommand ( )
Returns
bool
Exceptions
ilCtrlException

Reimplemented from ilObject2GUI.

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

114 {
115 global $DIC;
116
117 $ilNavigationHistory = $DIC['ilNavigationHistory'];
118 $ilHelp = $DIC['ilHelp'];
119 $ilHelp->setScreenIdComponent('bibl');
120
121 // Navigation History
122 $link = $DIC->ctrl()->getLinkTarget($this, "render");
123
124 if ($this->object != null) {
125 $ilNavigationHistory->addItem($this->object->getRefId(), $link, "dcl");
126 }
127
128 // Direct-Link Resource, redirect to viewgui
129 if ($_GET[self::GET_DCL_GTR]) {
130 $DIC->ctrl()->setParameterByClass(ilDclDetailedViewGUI::class, 'tableview_id', $_GET[self::GET_VIEW_ID]);
131 $DIC->ctrl()->setParameterByClass(ilDclDetailedViewGUI::class, 'record_id', $_GET[self::GET_DCL_GTR]);
132 $DIC->ctrl()->redirectByClass(ilDclDetailedViewGUI::class, 'renderRecord');
133 }
134
135
136 $next_class = $DIC->ctrl()->getNextClass($this);
137
138 if (!$this->getCreationMode() and $next_class != "ilinfoscreengui" and !$this->checkPermissionBool("read")) {
139 $DIC->ui()->mainTemplate()->getStandardTemplate();
140 $DIC->ui()->mainTemplate()->setContent("Permission Denied.");
141
142 return;
143 }
144
145 switch ($next_class) {
146 case "ilinfoscreengui":
147 $this->prepareOutput();
148 $DIC->tabs()->activateTab("id_info");
149 $this->infoScreenForward();
150 break;
151
152 case "ilcommonactiondispatchergui":
154 $gui->enableCommentsSettings(false);
155 $this->ctrl->forwardCommand($gui);
156 break;
157
158 case "ilpermissiongui":
159 $this->prepareOutput();
160 $DIC->tabs()->activateTab("id_permissions");
161 $perm_gui = new ilPermissionGUI($this);
162 $this->ctrl->forwardCommand($perm_gui);
163 break;
164
165 case "ilobjectcopygui":
166 $cp = new ilObjectCopyGUI($this);
167 $cp->setType("dcl");
168 $DIC->ui()->mainTemplate()->getStandardTemplate();
169 $this->ctrl->forwardCommand($cp);
170 break;
171
172 case "ildcltablelistgui":
173 $this->prepareOutput();
174 $DIC->tabs()->setTabActive("id_tables");
175 $tablelist_gui = new ilDclTableListGUI($this);
176 $this->ctrl->forwardCommand($tablelist_gui);
177 break;
178
179 case "ildclrecordlistgui":
180 $this->addHeaderAction(false);
181 $this->prepareOutput();
182 $DIC->tabs()->activateTab("id_records");
183 $this->ctrl->setParameterByClass(ilDclRecordListGUI::class, 'tableview_id', $_REQUEST['tableview_id']);
184 $recordlist_gui = new ilDclRecordListGUI($this, $this->table_id);
185 $this->ctrl->forwardCommand($recordlist_gui);
186 break;
187
188 case "ildclrecordeditgui":
189 $this->prepareOutput();
190 $DIC->tabs()->activateTab("id_records");
191 $recordedit_gui = new ilDclRecordEditGUI($this);
192 $this->ctrl->forwardCommand($recordedit_gui);
193 break;
194
195 case "ilobjfilegui":
196 $this->prepareOutput();
197 $DIC->tabs()->setTabActive("id_records");
198 $file_gui = new ilObjFile($this);
199 $this->ctrl->forwardCommand($file_gui);
200 break;
201
202 case "ilratinggui":
203 $rgui = new ilRatingGUI();
204 $rgui->setObject($_GET['record_id'], "dcl_record", $_GET["field_id"], "dcl_field");
205 $rgui->executeCommand();
206 $DIC->ctrl()->redirectByClass("ilDclRecordListGUI", "listRecords");
207 break;
208
209 case "ildcldetailedviewgui":
210 $this->prepareOutput();
211 $recordview_gui = new ilDclDetailedViewGUI($this);
212 $this->ctrl->forwardCommand($recordview_gui);
213 $DIC->tabs()->clearTargets();
214 $DIC->tabs()->setBackTarget($this->lng->txt("back"), $DIC->ctrl()->getLinkTargetByClass(ilDclRecordListGUI::class, ilDclRecordListGUI::CMD_LIST_RECORDS));
215 break;
216
217 case 'ilnotegui':
218 $this->prepareOutput();
219 $recordviewGui = new ilDclDetailedViewGUI($this);
220 $this->ctrl->forwardCommand($recordviewGui);
221 $DIC->tabs()->clearTargets();
222 $DIC->tabs()->setBackTarget($this->lng->txt("back"), $DIC->ctrl()->getLinkTarget($this, ""));
223 break;
224 case "ildclexportgui":
225 $this->prepareOutput();
226 $DIC->tabs()->setTabActive("export");
227 $exp_gui = new ilDclExportGUI($this);
228 $exporter = new ilDclContentExporter($this->object->getRefId());
229 $exp_gui->addFormat("xlsx", $this->lng->txt('dlc_xls_async_export'), $exporter, 'exportAsync');
230 $exp_gui->addFormat("xml");
231
232 $this->ctrl->forwardCommand($exp_gui);
233 break;
234
235 case strtolower(ilDclPropertyFormGUI::class):
236 $recordedit_gui = new ilDclRecordEditGUI($this);
237 $recordedit_gui->getRecord();
238 $recordedit_gui->initForm();
239 $form = $recordedit_gui->getForm();
240 $this->ctrl->forwardCommand($form);
241 break;
242
243 default:
244 return parent::executeCommand();
245 }
246
247 return true;
248 }
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
Hook-Class for exporting data-collections (used in SOAP-Class) This Class avoids duplicated code by r...
Export User Interface Class.
Class ilDclRecordEditGUI.
Class ilDclTableListGUI.
infoScreenForward()
show information screen
Class ilObjFile.
prepareOutput($a_show_subobjects=true)
prepare output
checkPermissionBool($a_perm, $a_cmd="", $a_type="", $a_node_id=null)
Check permission.
getCreationMode()
get creation mode
GUI class for the workflow of copying objects.
addHeaderAction()
Add header action menu.
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
Class ilRatingGUI.
if(isset($_POST['submit'])) $form

References $_GET, $DIC, $form, ilObjectGUI\addHeaderAction(), ilObject2GUI\checkPermissionBool(), ilDclRecordListGUI\CMD_LIST_RECORDS, ilObject2GUI\getCreationMode(), ilCommonActionDispatcherGUI\getInstanceFromAjaxCall(), infoScreenForward(), and ilObject2GUI\prepareOutput().

+ Here is the call graph for this function:

◆ getDataCollectionObject()

ilObjDataCollectionGUI::getDataCollectionObject ( )
Returns
ilObjDataCollection

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

441 {
442 $obj = new ilObjDataCollection($this->ref_id, true);
443
444 return $obj;
445 }
Class ilObjDataCollection.

Referenced by initEditCustomForm().

+ Here is the caller graph for this function:

◆ getEditFormCustomValues()

ilObjDataCollectionGUI::getEditFormCustomValues ( array &  $a_values)
Parameters
array$a_values
Returns
array|void

Reimplemented from ilObjectGUI.

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

454 {
455 $a_values["is_online"] = $this->object->getOnline();
456 $a_values["rating"] = $this->object->getRating();
457 $a_values["public_notes"] = $this->object->getPublicNotes();
458 $a_values["approval"] = $this->object->getApproval();
459 $a_values["notification"] = $this->object->getNotification();
460
461 return $a_values;
462 }

◆ getStandardCmd()

ilObjDataCollectionGUI::getStandardCmd ( )
Returns
string

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

95 {
96 return "render";
97 }

◆ getType()

ilObjDataCollectionGUI::getType ( )
Returns
string

Reimplemented from ilObject2GUI.

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

104 {
105 return "dcl";
106 }

◆ 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 256 of file class.ilObjDataCollectionGUI.php.

257 {
258 $this->ctrl->setCmd("showSummary");
259 $this->ctrl->setCmdClass("ilinfoscreengui");
260 $this->infoScreenForward();
261 }

References infoScreenForward().

+ Here is the call graph for this function:

◆ infoScreenForward()

ilObjDataCollectionGUI::infoScreenForward ( )

show information screen

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

280 {
281 global $DIC;
282 $ilTabs = $DIC['ilTabs'];
283 $ilErr = $DIC['ilErr'];
284
285 $ilTabs->activateTab("id_info");
286
287 if (!$this->checkPermissionBool("visible") && !$this->checkPermissionBool("read")) {
288 $ilErr->raiseError($this->lng->txt("msg_no_perm_read"));
289 }
290
291 $info = new ilInfoScreenGUI($this);
292 $info->enablePrivateNotes();
293 $info->addMetaDataSections($this->object->getId(), 0, $this->object->getType());
294
295 $this->ctrl->forwardCommand($info);
296 }
Class ilInfoScreenGUI.
$info
Definition: index.php:5

References $DIC, ilObjectGUI\$ilErr, $info, and ilObject2GUI\checkPermissionBool().

Referenced by executeCommand(), and infoScreen().

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

◆ initCreationForms()

ilObjDataCollectionGUI::initCreationForms (   $a_new_type)
protected
Parameters
string$a_new_type
Returns
array

Reimplemented from ilObject2GUI.

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

333 {
334 $forms = parent::initCreationForms($a_new_type);
335
336 return $forms;
337 }

◆ initEditCustomForm()

ilObjDataCollectionGUI::initEditCustomForm ( ilPropertyFormGUI  $a_form)
protected
Parameters
ilPropertyFormGUI$a_form

Reimplemented from ilObjectGUI.

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

401 {
402 global $DIC;
403 $ilTabs = $DIC['ilTabs'];
404
405 $ilTabs->activateTab("id_settings");
406
407 // is_online
408 $cb = new ilCheckboxInputGUI($this->lng->txt("online"), "is_online");
409 $cb->setInfo($this->lng->txt("dcl_online_info"));
410 $a_form->addItem($cb);
411
412 // Notification
413 $cb = new ilCheckboxInputGUI($this->lng->txt("dcl_activate_notification"), "notification");
414 $cb->setInfo($this->lng->txt("dcl_notification_info"));
415 $a_form->addItem($cb);
416
417 //table order
418 $order_options = array();
419 foreach ($this->getDataCollectionObject()->getTables() as $table) {
420 $order_options[$table->getId()] = $table->getTitle();
421 }
422 }
This class represents a checkbox property in a property form.
addItem($a_item)
Add Item (Property, SectionHeader).
if(empty($password)) $table
Definition: pwgen.php:24

References $DIC, $table, ilPropertyFormGUI\addItem(), and getDataCollectionObject().

+ Here is the call graph for this function:

◆ listRecords()

ilObjDataCollectionGUI::listRecords ( )

called by goto

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

429 {
430 global $DIC;
431 $ilCtrl = $DIC['ilCtrl'];
432 $ilCtrl->setParameterByClass("ildclrecordlistgui", "tableview_id", $_GET["tableview_id"]);
433 $ilCtrl->redirectByClass("ildclrecordlistgui", "show");
434 }

References $_GET, $DIC, and $ilCtrl.

◆ render()

ilObjDataCollectionGUI::render ( )

show Content; redirect to ilDclRecordListGUI::listRecords

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

268 {
269 global $DIC;
270 $ilCtrl = $DIC['ilCtrl'];
271 $this->ctrl->setParameterByClass('ilDclRecordListGUI', 'tableview_id', $_GET['tableview_id']);
272 $ilCtrl->redirectByClass("ildclrecordlistgui", "show");
273 }

References $_GET, $DIC, and $ilCtrl.

◆ setTabs()

ilObjDataCollectionGUI::setTabs ( )

setTabs create tabs (repository/workspace switch)

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

Reimplemented from ilObject2GUI.

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

357 {
358 global $DIC;
359 $ilAccess = $DIC['ilAccess'];
360 $ilTabs = $DIC['ilTabs'];
361 $lng = $DIC['lng'];
362 $ilHelp = $DIC['ilHelp'];
363
364 $ilHelp->setScreenIdComponent("dcl");
365
366 // list records
367 if ($ilAccess->checkAccess('read', "", $this->object->getRefId())) {
368 $ilTabs->addTab("id_records", $lng->txt("content"), $this->ctrl->getLinkTargetByClass("ildclrecordlistgui", "show"));
369 }
370
371 // info screen
372 if ($ilAccess->checkAccess('visible', "", $this->object->getRefId()) || $ilAccess->checkAccess('read', "", $this->object->getRefId())) {
373 $ilTabs->addTab("id_info", $lng->txt("info_short"), $this->ctrl->getLinkTargetByClass("ilinfoscreengui", "showSummary"));
374 }
375
376 // settings
377 if ($ilAccess->checkAccess('write', "", $this->object->getRefId())) {
378 $ilTabs->addTab("id_settings", $lng->txt("settings"), $this->ctrl->getLinkTarget($this, "editObject"));
379 }
380
381 // list tables
382 if ($ilAccess->checkAccess('write', "", $this->object->getRefId())) {
383 $ilTabs->addTab("id_tables", $lng->txt("dcl_tables"), $this->ctrl->getLinkTargetByClass("ildcltablelistgui", "listTables"));
384 }
385
386 // export
387 if ($ilAccess->checkAccess("write", "", $this->object->getRefId())) {
388 $ilTabs->addTab("export", $lng->txt("export"), $this->ctrl->getLinkTargetByClass("ildclexportgui", ""));
389 }
390
391 // edit permissions
392 if ($ilAccess->checkAccess('edit_permission', "", $this->object->getRefId())) {
393 $ilTabs->addTab("id_permissions", $lng->txt("perm_settings"), $this->ctrl->getLinkTargetByClass("ilpermissiongui", "perm"));
394 }
395 }

References $DIC, and ilObjectGUI\$lng.

◆ toggleNotification()

ilObjDataCollectionGUI::toggleNotification ( )

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

496 {
497 global $DIC;
498 $ilCtrl = $DIC['ilCtrl'];
499 $ilUser = $DIC['ilUser'];
500
501 switch ($_GET["ntf"]) {
502 case 1:
504 break;
505 case 2:
507 break;
508 }
509 $ilCtrl->redirectByClass("ildclrecordlistgui", "show");
510 }
static setNotification($type, $user_id, $id, $status=true)
Set notification status for object and user.

References $_GET, $DIC, $ilCtrl, $ilUser, ilNotification\setNotification(), and ilNotification\TYPE_DATA_COLLECTION.

+ Here is the call graph for this function:

◆ updateCustom()

ilObjDataCollectionGUI::updateCustom ( ilPropertyFormGUI  $a_form)
Parameters
ilPropertyFormGUI$a_form

Reimplemented from ilObjectGUI.

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

469 {
470 $this->object->setOnline($a_form->getInput("is_online"));
471 $this->object->setRating($a_form->getInput("rating"));
472 $this->object->setPublicNotes($a_form->getInput("public_notes"));
473 $this->object->setApproval($a_form->getInput("approval"));
474 $this->object->setNotification($a_form->getInput("notification"));
475
476 $this->emptyInfo();
477 }
getInput($a_post_var, $ensureValidation=true)
Returns the value of a HTTP-POST variable, identified by the passed id.

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

+ Here is the call graph for this function:

Field Documentation

◆ GET_DCL_GTR

const ilObjDataCollectionGUI::GET_DCL_GTR = "dcl_gtr"

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

Referenced by _goto().

◆ GET_REF_ID

const ilObjDataCollectionGUI::GET_REF_ID = "ref_id"

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

Referenced by _goto().

◆ GET_VIEW_ID

const ilObjDataCollectionGUI::GET_VIEW_ID = "tableview_id"

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

Referenced by _goto().


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