21require_once
"./Services/Container/classes/class.ilContainerGUI.php";
36 public function __construct($a_data, $a_id = 0, $a_call_by_reference =
true, $a_prepare_output =
false)
40 $this->tree =
$DIC->repositoryTree();
41 $this->tabs =
$DIC->tabs();
42 $this->
user = $DIC->user();
43 $this->ctrl =
$DIC->ctrl();
44 $this->lng =
$DIC->language();
45 $this->access =
$DIC->access();
46 $this->rbacsystem =
$DIC->rbac()->system();
47 $this->help =
$DIC[
"ilHelp"];
48 $this->
error = $DIC[
"ilErr"];
49 $this->tpl =
$DIC[
"tpl"];
52 parent::__construct($a_data, $a_id, $a_call_by_reference, $a_prepare_output,
false);
54 $this->lng->loadLanguageModule(
"obj");
67 if (strtolower(
$_GET[
"baseClass"]) ==
"iladministrationgui") {
73 include_once
'Services/Tracking/classes/class.ilLearningProgress.php';
76 $this->object->getId(),
77 $this->object->getRefId(),
82 $this->tabs_gui->setTabActive(
'view_content');
95 $ilTabs->activateTab(
"view_content");
96 $ret = parent::renderObject();
105 $next_class = $this->ctrl->getNextClass($this);
106 $cmd = $this->ctrl->getCmd();
111 switch ($next_class) {
112 case 'ilpermissiongui':
114 $this->tabs_gui->setTabActive(
'perm_settings');
115 include_once(
"Services/AccessControl/classes/class.ilPermissionGUI.php");
117 $ret = &$this->ctrl->forwardCommand($perm_gui);
121 case 'ilcoursecontentgui':
123 include_once
'./Modules/Course/classes/class.ilCourseContentGUI.php';
125 $this->ctrl->forwardCommand($course_content_obj);
128 case "illearningprogressgui":
130 include_once
'./Services/Tracking/classes/class.ilLearningProgressGUI.php';
134 $this->object->getRefId(),
137 $this->ctrl->forwardCommand($new_gui);
138 $this->tabs_gui->setTabActive(
'learning_progress');
142 case "ilcontainerpagegui":
146 $this->tpl->setContent(
$ret);
150 case 'ilinfoscreengui':
155 case 'ilobjectcopygui':
158 include_once
'./Services/Object/classes/class.ilObjectCopyGUI.php';
160 $cp->setType(
'fold');
161 $this->ctrl->forwardCommand($cp);
164 case "ilobjstylesheetgui":
171 $this->tabs_gui->setTabActive(
'export');
172 include_once
'./Services/Export/classes/class.ilExportGUI.php';
174 $exp->addFormat(
'xml');
175 $this->ctrl->forwardCommand($exp);
178 case "ilcommonactiondispatchergui":
179 include_once(
"Services/Object/classes/class.ilCommonActionDispatcherGUI.php");
181 $this->ctrl->forwardCommand($gui);
184 case 'ildidactictemplategui':
185 $this->ctrl->setReturn($this,
'edit');
186 include_once
'./Services/DidacticTemplate/classes/class.ilDidacticTemplateGUI.php';
188 $this->ctrl->forwardCommand($did);
191 $this->tabs_gui->setTabActive(
'none');
196 case 'ilbackgroundtaskhub':
197 include_once
'./Services/BackgroundTask/classes/class.ilBackgroundTaskHub.php';
199 $this->ctrl->forwardCommand($bggui);
202 case 'ilobjecttranslationgui':
206 include_once(
"./Services/Object/classes/class.ilObjectTranslationGUI.php");
208 $this->ctrl->forwardCommand($transgui);
234 $this->folder_tree = &$a_tree;
247 if (parent::importFileObject($parent_id, $a_catch_errors)) {
248 ilUtil::sendSuccess(
$lng->txt(
"msg_obj_modified"),
true);
249 $this->ctrl->returnToParent($this);
264 $lng->loadLanguageModule($this->object->getType());
266 include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
268 $form->setFormAction($this->ctrl->getFormAction($this,
"update"));
269 $form->setTitle($this->lng->txt($this->object->getType() .
"_edit"));
275 $ti->setRequired(
true);
288 $pres->setTitle($this->lng->txt(
'fold_presentation'));
289 $form->addItem($pres);
292 $form = $obj_service->commonSettings()->legacyForm(
$form, $this->
object)->addTitleIconVisibility();
295 $form = $obj_service->commonSettings()->legacyForm(
$form, $this->
object)->addTopActionsVisibility();
298 $form = $obj_service->commonSettings()->legacyForm(
$form, $this->
object)->addIcon();
301 $form = $obj_service->commonSettings()->legacyForm(
$form, $this->
object)->addTileImage();
316 $form->addCommandButton(
"update", $this->lng->txt(
"save"));
326 include_once
'./Services/Container/classes/class.ilContainerSortingSettings.php';
328 $a_values[
"sor"] = $sort->getSortMode();
336 $obj_service->commonSettings()->legacyForm($a_form, $this->
object)->saveTitleIconVisibility();
339 $obj_service->commonSettings()->legacyForm($a_form, $this->
object)->saveTopActionsVisibility();
342 $obj_service->commonSettings()->legacyForm($a_form, $this->
object)->saveIcon();
345 $obj_service->commonSettings()->legacyForm($a_form, $this->
object)->saveTileImage();
361 $this->ctrl->setCmd(
"showSummary");
362 $this->ctrl->setCmdClass(
"ilinfoscreengui");
368 include_once
'./Services/Container/classes/class.ilContainerSortingSettings.php';
374 ilUtil::sendSuccess($this->lng->txt(
"fold_added"),
true);
375 $this->ctrl->setParameter($this,
"ref_id", $a_new_object->
getRefId());
386 $this->ctrl->setCmd(
"showSummary");
387 $this->ctrl->setCmdClass(
"ilinfoscreengui");
398 if (!$ilAccess->checkAccess(
"visible",
"", $this->ref_id)) {
399 $this->
ilias->raiseError($this->lng->txt(
"msg_no_perm_read"), $this->ilias->error_obj->MESSAGE);
402 include_once(
"./Services/InfoScreen/classes/class.ilInfoScreenGUI.php");
405 $GLOBALS[
'ilTabs']->activateTab(
'info_short');
407 $info->enablePrivateNotes();
409 if ($ilAccess->checkAccess(
"read",
"",
$_GET[
"ref_id"])) {
414 $info->enableNewsEditing(
false);
415 if ($ilAccess->checkAccess(
"write",
"",
$_GET[
"ref_id"])) {
417 $enable_internal_rss = $news_set->get(
"enable_rss_for_internal");
419 if ($enable_internal_rss) {
420 $info->setBlockProperty(
"news",
"settings",
true);
421 $info->setBlockProperty(
"news",
"public_notifications_option",
true);
427 $info->addMetaDataSections($this->object->getId(), 0, $this->object->getType());
430 $this->ctrl->forwardCommand(
$info);
445 $this->ctrl->setParameter($this,
"ref_id", $this->ref_id);
447 $ilHelp->setScreenIdComponent(
"fold");
449 $this->tabs_gui->setTabActive(
"");
450 if (
$rbacsystem->checkAccess(
'read', $this->ref_id)) {
451 $this->tabs_gui->addTab(
453 $lng->txt(
"content"),
454 $this->ctrl->getLinkTarget($this,
"")
458 $force_active = ($this->ctrl->getNextClass() ==
"ilinfoscreengui"
459 || strtolower(
$_GET[
"cmdClass"]) ==
"ilnotegui")
462 $this->tabs_gui->addTarget(
464 $this->ctrl->getLinkTargetByClass(
465 array(
"ilobjfoldergui",
"ilinfoscreengui"),
468 array(
"showSummary",
"",
"infoScreen"),
476 if (
$rbacsystem->checkAccess(
'write', $this->ref_id)) {
477 $this->tabs_gui->addTarget(
479 $this->ctrl->getLinkTarget($this,
"edit"),
488 include_once
'./Services/Tracking/classes/class.ilLearningProgressAccess.php';
490 $this->tabs_gui->addTarget(
492 $this->ctrl->getLinkTargetByClass(array(
'ilobjfoldergui',
'illearningprogressgui'),
''),
494 array(
'illplistofobjectsgui',
'illplistofsettingsgui',
'illearningprogressgui',
'illplistofprogressgui')
498 if ($ilAccess->checkAccess(
'write',
'', $this->object->getRefId())) {
499 $this->tabs_gui->addTarget(
501 $this->ctrl->getLinkTargetByClass(
'ilexportgui',
''),
508 if (
$rbacsystem->checkAccess(
'edit_permission', $this->ref_id)) {
509 $this->tabs_gui->addTarget(
511 $this->ctrl->getLinkTargetByClass(array(get_class($this),
'ilpermissiongui'),
"perm"),
512 array(
"perm",
"info",
"owner"),
518 if (
$_GET[
"baseClass"] ==
"ilRepositoryGUI" and !empty(
$_SESSION[
'il_rep_clipboard'])) {
519 $this->tabs_gui->addTarget(
521 $this->ctrl->getLinkTarget($this,
"clipboard"),
531 public static function _goto($a_target)
535 $ilAccess =
$DIC->access();
539 if ($ilAccess->checkAccess(
"read",
"", $a_target)) {
552 if (!$ilAccess->checkAccess(
"read",
"", $this->ref_id)) {
553 $this->
ilias->raiseError($this->lng->txt(
"msg_no_perm_read"), $this->ilias->error_obj->MESSAGE);
555 $filename = $this->
object->downloadFolder();
571 if ($course_ref_id =
$tree->checkForParentType($this->object->getRefId(),
'crs')) {
572 include_once(
"./Modules/Course/classes/class.ilObjCourse.php");
573 include_once(
"./Modules/Course/classes/class.ilObjCourseGUI.php");
577 'ilcoursecontentgui',
583 $this->object->getRefId()
592 if (!$crs_ref =
$tree->checkForParentType($this->ref_id,
'crs')) {
595 include_once
'./Modules/Course/classes/class.ilObjCourse.php';
602 include_once
'./Modules/Course/classes/class.ilCourseContentGUI.php';
604 $this->ctrl->setCmdClass(get_class($course_content_obj));
605 $this->ctrl->setCmd(
'editUserTimings');
606 $this->ctrl->forwardCommand($course_content_obj);
626 $ilTabs->activateTab(
"settings");
629 $ilErr->raiseError($this->lng->txt(
"msg_no_perm_write"),
$ilErr->MESSAGE);
651 $lng->txt(
"fold_settings"),
652 $this->ctrl->getLinkTarget($this,
'edit')
655 $this->tabs_gui->addSubTab(
657 $this->lng->txt(
"obj_multilinguality"),
658 $this->ctrl->getLinkTargetByClass(
"ilobjecttranslationgui",
"")
661 $ilTabs->activateSubTab($a_tab);
662 $ilTabs->activateTab(
"settings");
An exception for terminatinating execution or to throw for unit testing.
error($a_errmsg)
set error message @access public
background task hub (aka ajax handler, GUI)
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
& forwardToPageObject()
forward command to page object
getEditFormValues()
Get values for edit form.
initSortingForm(ilPropertyFormGUI $form, array $a_sorting_settings)
Append sorting settings to property form.
prepareOutput($a_show_subobjects=true)
prepare output
saveListPresentation(ilPropertyFormGUI $form)
Save list presentation setting.
forwardToStyleSheet()
Forward to style object.
initListPresentationForm(ilPropertyFormGUI $form)
Add list presentation settings to form.
saveSortingSettings(ilPropertyFormGUI $form)
Save sorting settings.
Class ilCourseContentGUI.
GUI class for didactic template settings inside repository objects.
Export User Interface Class.
static checkAccess($a_ref_id, $a_allow_only_read=true)
check access to learning progress
const LP_CONTEXT_REPOSITORY
Class ilObjUserTrackingGUI.
static _tracProgress($a_user_id, $a_obj_id, $a_ref_id, $a_obj_type='')
static _modifyItemGUI( $a_item_list_gui, $a_cmd_class, $a_item_data, $a_show_path, $a_abo_status, $a_course_ref_id, $a_course_obj_id, $a_parent_ref_id=0)
We need a static version of this, e.g.
static _lookupViewMode($a_id)
lookup view mode of container
static _lookupAboStatus($a_id)
setFolderTree($a_tree)
set tree
importFileObject($parent_id=null, $a_catch_errors=true)
Import file object @global type $lng.
modifyItemGUI($a_item_list_gui, $a_item_data, $a_show_path)
Modify Item ListGUI for presentation in container @global type $tree.
renderObject()
Render folder.
getEditFormCustomValues(array &$a_values)
Add values to custom edit fields.
executeCommand()
execute command note: this method is overwritten in all container objects
afterSave(ilObject $a_new_object)
Post (successful) object creation hook.
infoScreenObject()
this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually,...
updateCustom(ilPropertyFormGUI $a_form)
Insert custom update form values into object.
setSubTabs($a_tab)
Set sub tabs.
static _goto($a_target)
goto target group
showSummaryObject()
this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually,...
__construct($a_data, $a_id=0, $a_call_by_reference=true, $a_prepare_output=false)
Constructor @access public.
initEditForm()
Init object edit form.
infoScreen()
show information screen
GUI class for the workflow of copying objects.
checkPermission($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
Check permission and redirect on error.
static _gotoRepositoryNode($a_ref_id, $a_cmd="frameset")
Goto repository root.
checkPermissionBool($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
Check permission.
initDidacticTemplate(ilPropertyFormGUI $form)
Show didactic template types.
addHeaderAction()
Add header action menu.
getObjectService()
Get object service.
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 sav...
GUI class for object translation handling.
Class ilObject Basic functions for all objects.
static _lookupObjId($a_id)
const TITLE_LENGTH
max length of object title
getRefId()
get reference id @access public
getId()
get object id @access public
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
This class represents a text area property in a property form.
This class represents a text property in a property form.
static deliverFile( $a_file, $a_filename, $a_mime='', $isInline=false, $removeAfterDelivery=false, $a_exit_after=true)
deliver file for download via browser.
static getASCIIFilename($a_filename)
convert utf8 to ascii filename
$GLOBALS['JPEG_Segment_Names']
Global Variable: XMP_tag_captions.
redirection script todo: (a better solution should control the processing via a xml file)
if(isset($_POST['submit'])) $form