ILIAS  trunk Revision v11.0_alpha-1715-g7fc467680fb
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ilInfoScreenGUI Class Reference

Class ilInfoScreenGUI. More...

+ Collaboration diagram for ilInfoScreenGUI:

Public Member Functions

 __construct (?object $a_gui_object=null)
 
 executeCommand ()
 
 setMessageBox (ILIAS\UI\Component\MessageBox\MessageBox $a_val)
 
 getMessageBox ()
 
 setTableClass (string $a_val)
 
 getTableClass ()
 
 enablePrivateNotes (bool $a_enable=true)
 
 enableLearningProgress (bool $a_enable=true)
 
 enableAvailability (bool $a_enable=true)
 
 enableBookingInfo (bool $a_enable=true)
 
 enableFeedback (bool $a_enable=true)
 
 enableNews (bool $a_enable=true)
 
 enableNewsEditing (bool $a_enable=true)
 
 setBlockProperty (string $a_block_type, string $a_property, string $a_value)
 This function is supposed to be used for block type specific properties, that should be passed to ilBlockGUI->setProperty. More...
 
 getAllBlockProperties ()
 
 addSection (string $a_title)
 
 setFormAction (string $a_form_action)
 
 removeFormAction ()
 
 addProperty (string $a_name, string $a_value, string $a_link="")
 add a property to current section More...
 
 addPropertyTextinput (string $a_name, string $a_input_name, string $a_input_value="", string $a_input_size="", string $direct_button_command="", string $direct_button_label="", bool $direct_button_primary=false)
 
 addButton (string $a_title, string $a_link, string $a_frame="", string $a_position="top", bool $a_primary=false)
 
 addFormButton (string $a_command, string $a_title, string $a_position="top")
 add a form button to the info screen the form buttons are only valid if a form action is set More...
 
 addHiddenElement (string $a_name, string $a_value)
 
 addMetaDataSections (int $a_rep_obj_id, int $a_obj_id, string $a_type)
 
 showSummary ()
 
 getCenterColumnHTML ()
 
 getRightColumnHTML ()
 
 setColumnSettings (ilColumnGUI $column_gui)
 Set column settings. More...
 
 setOpenFormTag (bool $a_val)
 
 setCloseFormTag (bool $a_val)
 
 getHTML ()
 
 getContextRefId ()
 
 setContextRefId (int $contextRefId)
 
 getContextObjId ()
 
 setContextObjId (int $contextObjId)
 
 getContentObjType ()
 
 setContentObjType (string $contentObjType)
 
 showLearningProgress (ilTemplate $a_tpl)
 
 saveProgress (bool $redirect=true)
 
 showNotesSection ()
 
 showLDAPRoleGroupMappingInfo (string $a_section='')
 
 setTabs ()
 
 getTabs (ilTabsGUI $tabs_gui)
 
 hideFurtherSections (bool $a_add_toggle=true)
 
 getHiddenToggleButton ()
 
 addAccessPeriodProperty ()
 

Data Fields

ilLanguage $lng
 
ilCtrl $ctrl
 
object $gui_object
 
array $top_buttons = array()
 
array $top_formbuttons = array()
 
array $hiddenelements = array()
 
string $table_class = "il_InfoScreen"
 
bool $open_form_tag = true
 
bool $close_form_tag = true
 
string $form_action
 

Protected Member Functions

 buildPublicAccessExportButton (int $rep_obj_id, int $obj_id)
 
 addAvailability ()
 
 addPreconditions ()
 Add preconditions. More...
 
 addPreconditionSection (ilObject $obj, array $conditions, bool $obligatory=true)
 

Protected Attributes

ILIAS Repository HTML HTMLUtil $html
 
ILIAS DI UIServices $ui
 
ILIAS UI Component MessageBox MessageBox $mbox = null
 
ilTabsGUI $tabs_gui
 
ilRbacSystem $rbacsystem
 
ilGlobalPageTemplate $tpl
 
ilAccessHandler $access
 
ilObjUser $user
 
ilTree $tree
 
ilSetting $settings
 
Metadata $metadata
 
DataFactory $data_factory
 
int $contextRefId = null
 
int $contextObjId = null
 
string $contentObjType = null
 
bool $booking_enabled = false
 
bool $availability_enabled = true
 
bool $hidden = false
 
array $section = []
 
array $block_property = []
 
bool $news_editing = false
 
bool $show_hidden_toggle = false
 
int $sec_nr = 0
 
bool $private_notes_enabled = false
 
bool $news_enabled = false
 
bool $feedback_enabled = false
 
bool $learning_progress_enabled = false
 
StandardGUIRequest $request
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilInfoScreenGUI::__construct ( ?object  $a_gui_object = null)

Definition at line 75 of file class.ilInfoScreenGUI.php.

References $DIC, $lng, ILIAS\Repository\access(), ILIAS\Repository\ctrl(), ILIAS\Repository\html(), ILIAS\Repository\lng(), ILIAS\Repository\settings(), ILIAS\Repository\ui(), and ILIAS\Repository\user().

76  {
77  global $DIC;
78 
79  $this->rbacsystem = $DIC->rbac()->system();
80  $this->tpl = $DIC["tpl"];
81  $this->access = $DIC->access();
82  $this->user = $DIC->user();
83  $this->tree = $DIC->repositoryTree();
84  $this->settings = $DIC->settings();
85  $ilCtrl = $DIC->ctrl();
86  $lng = $DIC->language();
87  $ilTabs = $DIC->tabs();
88  $this->metadata = $DIC->learningObjectMetadata();
89 
90  $this->ctrl = $ilCtrl;
91  $this->lng = $lng;
92  $this->tabs_gui = $ilTabs;
93  $this->gui_object = $a_gui_object;
94  $this->form_action = "";
95  $this->top_formbuttons = array();
96  $this->hiddenelements = array();
97  $this->ui = $DIC->ui();
98  $this->request = $DIC->infoScreen()->internal()->gui()->standardRequest();
99  $this->html = $DIC->infoScreen()->internal()->gui()->html();
100  $this->data_factory = new DataFactory();
101  }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
global $DIC
Definition: shib_login.php:22
+ Here is the call graph for this function:

Member Function Documentation

◆ addAccessPeriodProperty()

ilInfoScreenGUI::addAccessPeriodProperty ( )
Exceptions
ilDatabaseException
ilDateTimeException

Definition at line 1219 of file class.ilInfoScreenGUI.php.

References addProperty(), ilDatePresentation\formatPeriod(), IL_CAL_UNIX, ILIAS\Repository\lng(), and ilObjectActivation\TIMINGS_ACTIVATION.

Referenced by addAvailability().

1219  : void
1220  {
1221  $a_obj = $this->gui_object->getObject();
1222 
1223  $this->lng->loadLanguageModule("rep");
1224  $this->lng->loadLanguageModule("crs");
1225 
1226  // links to the object
1227  if (is_object($a_obj)) {
1228  $act = new ilObjectActivation();
1229  $act->read($a_obj->getRefId());
1230  if ($act->getTimingType() == ilObjectActivation::TIMINGS_ACTIVATION) {
1231  $this->addProperty(
1232  $this->lng->txt('rep_activation_access'),
1234  new ilDateTime($act->getTimingStart(), IL_CAL_UNIX),
1235  new ilDateTime($act->getTimingEnd(), IL_CAL_UNIX)
1236  )
1237  );
1238  } else {
1239  $this->addProperty(
1240  $this->lng->txt('rep_activation_access'),
1241  $this->lng->txt('crs_visibility_limitless')
1242  );
1243  }
1244  }
1245  }
addProperty(string $a_name, string $a_value, string $a_link="")
add a property to current section
const IL_CAL_UNIX
Class ilObjectActivation.
static formatPeriod(ilDateTime $start, ilDateTime $end, bool $a_skip_starting_day=false, ?ilObjUser $user=null)
Format a period of two dates Shows: 14.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addAvailability()

ilInfoScreenGUI::addAvailability ( )
protected
Exceptions
ilDatabaseException
ilDateTimeException

Definition at line 1080 of file class.ilInfoScreenGUI.php.

References addAccessPeriodProperty(), addSection(), ILIAS\Repository\lng(), and ilObjectActivation\TIMINGS_ACTIVATION.

Referenced by getHTML().

1080  : void
1081  {
1082  if (
1083  !is_object($this->gui_object) ||
1084  !method_exists($this->gui_object, "getObject") ||
1085  !is_object($this->gui_object->getObject())
1086  ) {
1087  return;
1088  }
1089 
1090  $obj = $this->gui_object->getObject();
1091  if ($obj->getRefId() <= 0) {
1092  return;
1093  }
1094 
1095  $act = new ilObjectActivation();
1096  $act->read($obj->getRefId());
1097  if ($act->getTimingType() == ilObjectActivation::TIMINGS_ACTIVATION) {
1098  $this->lng->loadLanguageModule("rep");
1099  $this->addSection($this->lng->txt("rep_activation_availability"));
1100  $this->addAccessPeriodProperty();
1101  }
1102  }
addSection(string $a_title)
Class ilObjectActivation.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addButton()

ilInfoScreenGUI::addButton ( string  $a_title,
string  $a_link,
string  $a_frame = "",
string  $a_position = "top",
bool  $a_primary = false 
)
Deprecated:

Definition at line 292 of file class.ilInfoScreenGUI.php.

Referenced by getHTML().

298  : void {
299  if ($a_position == "top") {
300  $this->top_buttons[] =
301  array("title" => $a_title,"link" => $a_link,"target" => $a_frame,"primary" => $a_primary);
302  }
303  }
+ Here is the caller graph for this function:

◆ addFormButton()

ilInfoScreenGUI::addFormButton ( string  $a_command,
string  $a_title,
string  $a_position = "top" 
)

add a form button to the info screen the form buttons are only valid if a form action is set

Definition at line 309 of file class.ilInfoScreenGUI.php.

313  : void {
314  if ($a_position == "top") {
315  $this->top_formbuttons[] = array("command" => $a_command, "title" => $a_title);
316  }
317  }

◆ addHiddenElement()

ilInfoScreenGUI::addHiddenElement ( string  $a_name,
string  $a_value 
)

Definition at line 319 of file class.ilInfoScreenGUI.php.

319  : void
320  {
321  $this->hiddenelements[] = array("name" => $a_name, "value" => $a_value);
322  }

◆ addMetaDataSections()

ilInfoScreenGUI::addMetaDataSections ( int  $a_rep_obj_id,
int  $a_obj_id,
string  $a_type 
)

Definition at line 324 of file class.ilInfoScreenGUI.php.

References $lng, addProperty(), addSection(), buildPublicAccessExportButton(), ILIAS\Repository\html(), ilLanguage\loadLanguageModule(), ilLanguage\txt(), and ILIAS\Repository\ui().

324  : void
325  {
326  $lng = $this->lng;
327 
328  $lng->loadLanguageModule("meta");
329  $lng->loadLanguageModule('export');
330 
331  $md_reader = $this->metadata->read($a_rep_obj_id, $a_obj_id, $a_type);
332  $md_paths = $this->metadata->paths();
333  $md_data_helper = $this->metadata->dataHelper();
334  $md_copyright_helper = $this->metadata->copyrightHelper();
335 
336  // general
337  $lang_data = $md_reader->allData($md_paths->languages());
338  $langs = $md_data_helper->makePresentableAsList(', ', ...$lang_data);
339 
340  $keyword_data = $md_reader->allData($md_paths->keywords());
341  $keywords = $md_data_helper->makePresentableAsList(', ', ...$keyword_data);
342 
343  // authors
344  $author_data = $md_reader->allData($md_paths->authors());
345  $author = $md_data_helper->makePresentableAsList(', ', ...$author_data);
346 
347  // learning time
348  $learning_time_data = $md_reader->firstData($md_paths->firstTypicalLearningTime());
349  $learning_time = $md_data_helper->makePresentable($learning_time_data);
350 
351  // copyright
352  $copyright = '';
353  if ($md_copyright_helper->hasPresetCopyright($md_reader)) {
354  $copyright = $this->ui->renderer()->render(
355  $md_copyright_helper->readPresetCopyright($md_reader)->presentAsUIComponents()
356  );
357  } else {
358  $copyright = $md_copyright_helper->readCustomCopyright($md_reader);
359  }
360 
361  // public access export
362  $public_access_export = $this->buildPublicAccessExportButton($a_rep_obj_id, $a_obj_id);
363 
364  // output
365 
366  // general section
367  $this->addSection($lng->txt("meta_general"));
368  if ($langs != "") { // language
369  $this->addProperty(
370  $lng->txt("language"),
371  $this->html->escape($langs)
372  );
373  }
374  if ($keywords != "") { // keywords
375  $this->addProperty(
376  $lng->txt("keywords"),
377  $this->html->escape($keywords)
378  );
379  }
380  if ($author != "") { // author
381  $this->addProperty(
382  $lng->txt("author"),
383  $this->html->escape($author)
384  );
385  }
386  if ($learning_time != "") { // typical learning time
387  $this->addProperty(
388  $lng->txt("meta_typical_learning_time"),
389  $this->html->escape($learning_time)
390  );
391  }
392 
393  // licence and use section
394  if ($copyright === '' && $public_access_export === '') {
395  return;
396  }
397  $this->addSection($lng->txt('meta_info_licence_section'));
398 
399  if ($public_access_export !== '') { // public access export
400  $this->addProperty(
401  $lng->txt('export_info_public_access'),
402  $public_access_export
403  );
404  }
405 
406  if ($copyright !== '') { // copyright
407  $this->addProperty(
408  $lng->txt("meta_copyright"),
409  $copyright
410  );
411  }
412  }
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...
addProperty(string $a_name, string $a_value, string $a_link="")
add a property to current section
loadLanguageModule(string $a_module)
Load language module.
buildPublicAccessExportButton(int $rep_obj_id, int $obj_id)
addSection(string $a_title)
+ Here is the call graph for this function:

◆ addPreconditions()

ilInfoScreenGUI::addPreconditions ( )
protected

Add preconditions.

Definition at line 1107 of file class.ilInfoScreenGUI.php.

References ilObject\_lookupTitle(), addPreconditionSection(), and ilArrayUtil\sortArray().

Referenced by getHTML().

1107  : void
1108  {
1109  if (
1110  !is_object($this->gui_object) ||
1111  !method_exists($this->gui_object, "getObject") ||
1112  !is_object($this->gui_object->getObject())
1113  ) {
1114  return;
1115  }
1116 
1117  $obj = $this->gui_object->getObject();
1118  if ($obj->getRefId() <= 0) {
1119  return;
1120  }
1121 
1122  $conditions = ilConditionHandler::_getEffectiveConditionsOfTarget($obj->getRefId(), $obj->getId());
1123 
1124  if (sizeof($conditions)) {
1125  for ($i = 0; $i < count($conditions); $i++) {
1126  $conditions[$i]['title'] = ilObject::_lookupTitle($conditions[$i]['trigger_obj_id']);
1127  }
1128  $conditions = ilArrayUtil::sortArray($conditions, 'title', 'DESC');
1129 
1130  // Show obligatory and optional preconditions seperated
1131  $this->addPreconditionSection($obj, $conditions, true);
1132  $this->addPreconditionSection($obj, $conditions, false);
1133  }
1134  }
addPreconditionSection(ilObject $obj, array $conditions, bool $obligatory=true)
static _lookupTitle(int $obj_id)
static sortArray(array $array, string $a_array_sortby_key, string $a_array_sortorder="asc", bool $a_numeric=false, bool $a_keep_keys=false)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addPreconditionSection()

ilInfoScreenGUI::addPreconditionSection ( ilObject  $obj,
array  $conditions,
bool  $obligatory = true 
)
protected

Definition at line 1136 of file class.ilInfoScreenGUI.php.

References $lng, $tree, ilConditionHandler\_checkCondition(), ilObject\_lookupTitle(), addProperty(), addSection(), ilConditionHandler\calculateEffectiveRequiredTriggers(), ilConditionHandler\getEffectiveOptionalConditionsOfTarget(), ilObject\getId(), ilMemberViewSettings\getInstance(), ilObject\getRefId(), ILIAS\Repository\html(), ilTree\isDeleted(), ilConditionHandlerGUI\translateOperator(), and ilLanguage\txt().

Referenced by addPreconditions().

1140  : void {
1141  $lng = $this->lng;
1142  $tree = $this->tree;
1143 
1144  $num_required = ilConditionHandler::calculateEffectiveRequiredTriggers($obj->getRefId(), $obj->getId());
1145  $num_optional_required =
1146  $num_required - count($conditions) + count(ilConditionHandler::getEffectiveOptionalConditionsOfTarget($obj->getRefId(), $obj->getId()));
1147 
1148  // Check if all conditions are fulfilled
1149  $visible_conditions = array();
1150  $passed_optional = 0;
1151  foreach ($conditions as $condition) {
1152  if ($obligatory and !$condition['obligatory']) {
1153  continue;
1154  }
1155  if (!$obligatory and $condition['obligatory']) {
1156  continue;
1157  }
1158 
1159  if ($tree->isDeleted($condition['trigger_ref_id'])) {
1160  continue;
1161  }
1162 
1163  $ok = ilConditionHandler::_checkCondition($condition) and
1164  !ilMemberViewSettings::getInstance()->isActive();
1165 
1166  if (!$ok) {
1167  $visible_conditions[] = $condition['id'];
1168  }
1169 
1170  if (!$obligatory and $ok) {
1171  ++$passed_optional;
1172  // optional passed
1173  if ($passed_optional >= $num_optional_required) {
1174  return;
1175  }
1176  }
1177  }
1178 
1179  $properties = [];
1180 
1181  foreach ($conditions as $condition) {
1182  if (!isset($condition["id"]) || !in_array($condition['id'], $visible_conditions)) {
1183  continue;
1184  }
1185 
1186  $properties[] = [
1188  $condition['trigger_obj_id'],
1189  $condition['operator']
1190  ) . ' ' . $condition['value'],
1191  "title" => ilObject::_lookupTitle($condition['trigger_obj_id']),
1192  "link" => ilLink::_getLink($condition['trigger_ref_id'])
1193  ];
1194  }
1195 
1196  if (count($properties) > 0) {
1197  if ($obligatory) {
1198  $this->addSection($lng->txt("preconditions_obligatory_hint"));
1199  } else {
1200  $this->addSection(sprintf(
1201  $lng->txt("preconditions_optional_hint"),
1202  $num_optional_required - $passed_optional
1203  ));
1204  }
1205 
1206  foreach ($properties as $p) {
1207  $this->addProperty(
1208  $p["condition"],
1209  "<a href='" . $p["link"] . "'>" . $this->html->strip($p["title"]) . "</a>"
1210  );
1211  }
1212  }
1213  }
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...
static translateOperator(int $a_obj_id, string $a_operator, string $value='')
addProperty(string $a_name, string $a_value, string $a_link="")
add a property to current section
isDeleted(int $a_node_id)
This is a wrapper for isSaved() with a more useful name.
static _checkCondition(array $condition, int $a_usr_id=0)
checks wether a single condition is fulfilled every trigger object type must implement a static metho...
static _lookupTitle(int $obj_id)
static calculateEffectiveRequiredTriggers(int $a_target_ref_id, int $a_target_obj_id, string $a_target_obj_type='')
addSection(string $a_title)
static getEffectiveOptionalConditionsOfTarget(int $a_target_ref_id, int $a_target_obj_id, string $a_obj_type='')
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addProperty()

ilInfoScreenGUI::addProperty ( string  $a_name,
string  $a_value,
string  $a_link = "" 
)

add a property to current section

Parameters
string$a_nameproperty name string
string$a_valueproperty value
string$a_linklink (will link the property value string)

Definition at line 249 of file class.ilInfoScreenGUI.php.

References $sec_nr.

Referenced by ilLearningProgressBaseGUI\__appendLPDetails(), ilLearningProgressBaseGUI\__showObjectDetails(), addAccessPeriodProperty(), ilObjIndividualAssessmentGUI\addContactDataToInfo(), ilObjRemoteCourseGUI\addCustomInfoFields(), ilObjRemoteGlossaryGUI\addCustomInfoFields(), ilObjRemoteGroupGUI\addCustomInfoFields(), ilObjRemoteTestGUI\addCustomInfoFields(), ilObjRemoteFileGUI\addCustomInfoFields(), ilObjRemoteLearningModuleGUI\addCustomInfoFields(), ilObjRemoteWikiGUI\addCustomInfoFields(), ilObjIndividualAssessmentGUI\addGeneralDataToInfo(), ilObjIndividualAssessmentGUI\addMemberDataToInfo(), addMetaDataSections(), addPreconditionSection(), ilObjGlossaryGUI\addUsagesToInfo(), ilResourceStorageInfoGUI\append(), buildPublicAccessExportButton(), ilAppointmentPresentationGUI\getHTML(), ilExSubmissionTextGUI\getOverviewContent(), ilExSubmissionFileGUI\getOverviewContent(), ilExSubmissionTeamGUI\getOverviewContent(), ilExPeerReviewGUI\getOverviewContent(), ilExSubmissionObjectGUI\getOverviewContentBlog(), ilExSubmissionObjectGUI\getOverviewContentPortfolio(), ilExAssTypeWikiTeamGUI\renderOverviewContent(), and showLDAPRoleGroupMappingInfo().

249  : void
250  {
251  $this->section[$this->sec_nr]["properties"][] =
252  array("name" => $a_name, "value" => $a_value,
253  "link" => $a_link);
254  }
+ Here is the caller graph for this function:

◆ addPropertyTextinput()

ilInfoScreenGUI::addPropertyTextinput ( string  $a_name,
string  $a_input_name,
string  $a_input_value = "",
string  $a_input_size = "",
string  $direct_button_command = "",
string  $direct_button_label = "",
bool  $direct_button_primary = false 
)
Deprecated:

Definition at line 260 of file class.ilInfoScreenGUI.php.

References $sec_nr, and ilLegacyFormElementsUtil\prepareFormOutput().

268  : void {
269  $input = "<span class=\"form-inline\"><input class=\"form-control\" type=\"text\" name=\"$a_input_name\" id=\"$a_input_name\"";
270  if (strlen($a_input_value)) {
271  $input .= " value=\"" . ilLegacyFormElementsUtil::prepareFormOutput($a_input_value) . "\"";
272  }
273  if (strlen($a_input_size)) {
274  $input .= " size=\"" . $a_input_size . "\"";
275  }
276  $input .= " />";
277  if (strlen($direct_button_command) && strlen($direct_button_label)) {
278  $css = "";
279  if ($direct_button_primary) {
280  $css = " btn-primary";
281  }
282  $input .= " <input type=\"submit\" class=\"btn btn-default" . $css . "\" name=\"cmd[$direct_button_command]\" value=\"$direct_button_label\" />";
283  }
284  $input .= "</span>";
285  $this->section[$this->sec_nr]["properties"][] =
286  array("name" => "<label for=\"$a_input_name\">$a_name</label>", "value" => $input);
287  }
static prepareFormOutput($a_str, bool $a_strip=false)
+ Here is the call graph for this function:

◆ addSection()

◆ buildPublicAccessExportButton()

ilInfoScreenGUI::buildPublicAccessExportButton ( int  $rep_obj_id,
int  $obj_id 
)
protected

Definition at line 414 of file class.ilInfoScreenGUI.php.

References $access, $ctrl, $lng, $r, $ref_id, $tree, $user, $webdav_dic, ilObject\_getAllReferences(), ilDAVActivationChecker\_isActive(), ilChangeEvent\_isActive(), ilChangeEvent\_lookupReadEvents(), addProperty(), addSection(), ANONYMOUS_USER_ID, ilDatePresentation\formatDate(), ilECSServerSettings\getInstance(), ilObjectFactory\getInstanceByObjId(), IL_CAL_DATETIME, ilTree\isInTree(), ILIAS\Repository\lng(), ilLanguage\txt(), ILIAS\Repository\ui(), and ilObjUser\userExists().

Referenced by addMetaDataSections().

414  : string
415  {
416  /*
417  * This should be replaced by a proper export API
418  * when it is available.
419  */
420  $export_services = new ExportServices();
421  $public_access = $export_services->publicAccess()->handler();
422 
423  /*
424  * Make sure we are not in a subobject, and that we will get
425  * the ref_id via the GUI from the correct object.
426  */
427  if (
428  $rep_obj_id !== $this->gui_object->getObject()->getId() ||
429  ($obj_id !== 0 && $obj_id !== $rep_obj_id)
430  ) {
431  return '';
432  }
433 
434  if (!$public_access->hasPublicAccessFile($this->data_factory->objId($rep_obj_id))) {
435  return '';
436  }
437 
438  $ref_id = $this->gui_object->getObject()->getRefId();
439 
440  return $this->ui->renderer()->render(
441  $this->ui->factory()->button()->standard(
442  $this->lng->txt('export_info_public_access_download'),
443  $public_access->downloadLinkOfPublicAccessFile($this->data_factory->refId($ref_id))
444  )
445  );
446  }
$ref_id
Definition: ltiauth.php:65
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ enableAvailability()

ilInfoScreenGUI::enableAvailability ( bool  $a_enable = true)

Definition at line 182 of file class.ilInfoScreenGUI.php.

182  : void
183  {
184  $this->availability_enabled = $a_enable;
185  }

◆ enableBookingInfo()

ilInfoScreenGUI::enableBookingInfo ( bool  $a_enable = true)

Definition at line 187 of file class.ilInfoScreenGUI.php.

187  : void
188  {
189  $this->booking_enabled = $a_enable;
190  }

◆ enableFeedback()

ilInfoScreenGUI::enableFeedback ( bool  $a_enable = true)

Definition at line 193 of file class.ilInfoScreenGUI.php.

193  : void
194  {
195  $this->feedback_enabled = $a_enable;
196  }

◆ enableLearningProgress()

ilInfoScreenGUI::enableLearningProgress ( bool  $a_enable = true)

Definition at line 177 of file class.ilInfoScreenGUI.php.

177  : void
178  {
179  $this->learning_progress_enabled = $a_enable;
180  }

◆ enableNews()

ilInfoScreenGUI::enableNews ( bool  $a_enable = true)

Definition at line 198 of file class.ilInfoScreenGUI.php.

198  : void
199  {
200  $this->news_enabled = $a_enable;
201  }

◆ enableNewsEditing()

ilInfoScreenGUI::enableNewsEditing ( bool  $a_enable = true)

Definition at line 203 of file class.ilInfoScreenGUI.php.

203  : void
204  {
205  $this->news_editing = $a_enable;
206  }

◆ enablePrivateNotes()

ilInfoScreenGUI::enablePrivateNotes ( bool  $a_enable = true)

Definition at line 172 of file class.ilInfoScreenGUI.php.

172  : void
173  {
174  $this->private_notes_enabled = $a_enable;
175  }

◆ executeCommand()

ilInfoScreenGUI::executeCommand ( )
Exceptions
ilCtrlException
ilDatabaseException
ilDateTimeException
ilObjectNotFoundException

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

References $tpl, ILIAS\Repository\ctrl(), ilCommonActionDispatcherGUI\getInstanceFromAjaxCall(), ilPublicUserProfileGUI\setBackUrl(), ilGlobalPageTemplate\setContent(), setTabs(), showNotesSection(), and showSummary().

109  : void
110  {
111  $tpl = $this->tpl;
112 
113  $next_class = $this->ctrl->getNextClass($this);
114 
115  $cmd = $this->ctrl->getCmd("showSummary");
116  $this->ctrl->setReturn($this, "showSummary");
117 
118  $this->setTabs();
119 
120  switch ($next_class) {
121  case strtolower(ilCommentGUI::class):
122  if ($this->ctrl->isAsynch()) {
123  $this->showNotesSection();
124  } else {
125  $this->showSummary(); // forwards command
126  }
127  break;
128 
129  case "ilcolumngui":
130  $this->showSummary();
131  break;
132 
133  case "ilpublicuserprofilegui":
134  $user_profile = new ilPublicUserProfileGUI($this->request->getUserId());
135  $user_profile->setBackUrl($this->ctrl->getLinkTarget($this, "showSummary"));
136  $html = $this->ctrl->forwardCommand($user_profile);
138  break;
139 
140  case "ilcommonactiondispatchergui":
142  $this->ctrl->forwardCommand($gui);
143  break;
144 
145  default:
146  $this->$cmd();
147  break;
148  }
149  }
if(!file_exists('../ilias.ini.php'))
setBackUrl(string $backurl)
Set Back Link URL.
GUI class for public user profile presentation.
ILIAS Repository HTML HTMLUtil $html
ilGlobalPageTemplate $tpl
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
setContent(string $a_html)
Sets content for standard template.
+ Here is the call graph for this function:

◆ getAllBlockProperties()

ilInfoScreenGUI::getAllBlockProperties ( )

Definition at line 217 of file class.ilInfoScreenGUI.php.

References $block_property.

Referenced by setColumnSettings().

217  : array
218  {
219  return $this->block_property;
220  }
+ Here is the caller graph for this function:

◆ getCenterColumnHTML()

ilInfoScreenGUI::getCenterColumnHTML ( )
Returns
string
Exceptions
ilCtrlException
ilDatabaseException
ilDateTimeException
ilObjectNotFoundException

Definition at line 627 of file class.ilInfoScreenGUI.php.

References $ctrl, $html, getHTML(), IL_COL_CENTER, IL_COL_LEFT, IL_COL_RIGHT, IL_SCREEN_SIDE, and setColumnSettings().

Referenced by showSummary().

627  : string
628  {
629  $ilCtrl = $this->ctrl;
630  $html = "";
631  $column_gui = new ilColumnGUI("info", IL_COL_CENTER);
632  $this->setColumnSettings($column_gui);
633 
634  if (!$ilCtrl->isAsynch()) {
635  if ($column_gui->getScreenMode() != IL_SCREEN_SIDE) {
636  // right column wants center
637  if ($column_gui->getCmdSide() == IL_COL_RIGHT) {
638  $column_gui = new ilColumnGUI("info", IL_COL_RIGHT);
639  $this->setColumnSettings($column_gui);
640  $html = $ilCtrl->forwardCommand($column_gui);
641  }
642  // left column wants center
643  if ($column_gui->getCmdSide() == IL_COL_LEFT) {
644  $column_gui = new ilColumnGUI("info", IL_COL_LEFT);
645  $this->setColumnSettings($column_gui);
646  $html = $ilCtrl->forwardCommand($column_gui);
647  }
648  } else {
649  $html = $this->getHTML();
650  }
651  }
652 
653  return $html;
654  }
const IL_COL_CENTER
const IL_COL_RIGHT
setColumnSettings(ilColumnGUI $column_gui)
Set column settings.
Column user interface class.
ILIAS Repository HTML HTMLUtil $html
const IL_SCREEN_SIDE
const IL_COL_LEFT
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getContentObjType()

ilInfoScreenGUI::getContentObjType ( )

Definition at line 884 of file class.ilInfoScreenGUI.php.

References $contentObjType, and null.

884  : string
885  {
886  if ($this->contentObjType !== null) {
887  return $this->contentObjType;
888  }
889 
890  return $this->gui_object->getObject()->getType();
891  }
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null

◆ getContextObjId()

ilInfoScreenGUI::getContextObjId ( )

Definition at line 870 of file class.ilInfoScreenGUI.php.

References $contextObjId, and null.

Referenced by ilBookingInfoScreenAdapter\__construct(), saveProgress(), and showLearningProgress().

870  : int
871  {
872  if ($this->contextObjId !== null) {
873  return $this->contextObjId;
874  }
875 
876  return $this->gui_object->getObject()->getId();
877  }
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
+ Here is the caller graph for this function:

◆ getContextRefId()

ilInfoScreenGUI::getContextRefId ( )

Definition at line 856 of file class.ilInfoScreenGUI.php.

References $contextRefId, and null.

Referenced by saveProgress().

856  : int
857  {
858  if ($this->contextRefId !== null) {
859  return $this->contextRefId;
860  }
861 
862  return $this->gui_object->getObject()->getRefId();
863  }
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
+ Here is the caller graph for this function:

◆ getHiddenToggleButton()

ilInfoScreenGUI::getHiddenToggleButton ( )

Definition at line 1068 of file class.ilInfoScreenGUI.php.

References $lng, and ilLanguage\txt().

1068  : string
1069  {
1070  $lng = $this->lng;
1071 
1072  return "<a onClick=\"toggleSections(this, '" . $lng->txt("show_hidden_sections") . "', '" . $lng->txt("hide_visible_sections") . "'); return false;\" href=\"#\">" . $lng->txt("show_hidden_sections") . "</a>";
1073  }
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...
+ Here is the call graph for this function:

◆ getHTML()

ilInfoScreenGUI::getHTML ( )
Returns
string
Exceptions
ilCtrlException
ilDatabaseException
ilDateTimeException
ilObjectNotFoundException

Definition at line 706 of file class.ilInfoScreenGUI.php.

References $ctrl, $ilSetting, $lng, $sec_nr, $settings, $user, addAvailability(), ilGlobalPageTemplate\addBlockFile(), addButton(), addPreconditions(), ilGlobalPageTemplate\get(), getTableClass(), iljQueryUtil\initjQuery(), ilGlobalPageTemplate\parseCurrentBlock(), ilGlobalPageTemplate\setCurrentBlock(), setFormAction(), ilGlobalPageTemplate\setVariable(), showLearningProgress(), showNotesSection(), ilGlobalPageTemplate\touchBlock(), ilLanguage\txt(), and ILIAS\Repository\ui().

Referenced by getCenterColumnHTML(), and ilCalendarAppointmentPresentationGUI\getModalHTML().

706  : string
707  {
708  $lng = $this->lng;
710  $ilCtrl = $this->ctrl;
711  $ilUser = $this->user;
712 
713  $tpl = new ilTemplate("tpl.infoscreen.html", true, true, "components/ILIAS/InfoScreen");
714 
715  // other class handles form action (@todo: this is not implemented/tested)
716  if ($this->form_action == "") {
717  $this->setFormAction($ilCtrl->getFormAction($this));
718  }
719 
721 
722  if ($this->hidden) {
723  $tpl->touchBlock("hidden_js");
724  if ($this->show_hidden_toggle) {
725  $this->addButton($lng->txt("show_hidden_sections"), "JavaScript:toggleSections(this, '" . $lng->txt("show_hidden_sections") . "', '" . $lng->txt("hide_visible_sections") . "');");
726  }
727  }
728 
729 
730  // DEPRECATED - use ilToolbarGUI
731 
732  // add top buttons
733  if (count($this->top_buttons) > 0) {
734  $tpl->addBlockFile("TOP_BUTTONS", "top_buttons", "tpl.buttons.html");
735 
736  foreach ($this->top_buttons as $button) {
737  // view button
738  $tpl->setCurrentBlock("btn_cell");
739  $tpl->setVariable("BTN_LINK", $button["link"]);
740  $tpl->setVariable("BTN_TARGET", $button["target"]);
741  $tpl->setVariable("BTN_TXT", $button["title"]);
742  if ($button["primary"]) {
743  $tpl->setVariable("BTN_CLASS", " btn-primary");
744  }
746  }
747  }
748 
749  // add top formbuttons
750  if ((count($this->top_formbuttons) > 0) && ($this->form_action !== '')) {
751  $tpl->addBlockFile("TOP_FORMBUTTONS", "top_submitbuttons", "tpl.submitbuttons.html", "components/ILIAS/InfoScreen");
752 
753  foreach ($this->top_formbuttons as $button) {
754  // view button
755  $tpl->setCurrentBlock("btn_submit_cell");
756  $tpl->setVariable("BTN_COMMAND", $button["command"]);
757  $tpl->setVariable("BTN_NAME", $button["title"]);
759  }
760  }
761 
762  // add form action
763  if ($this->form_action != "") {
764  if ($this->open_form_tag) {
765  $tpl->setCurrentBlock("formtop");
766  $tpl->setVariable("FORMACTION", $this->form_action);
768  }
769 
770  if ($this->close_form_tag) {
771  $tpl->touchBlock("formbottom");
772  }
773  }
774 
775  if (count($this->hiddenelements)) {
776  foreach ($this->hiddenelements as $hidden) {
777  $tpl->setCurrentBlock("hidden_element");
778  $tpl->setVariable("HIDDEN_NAME", $hidden["name"]);
779  $tpl->setVariable("HIDDEN_VALUE", $hidden["value"]);
781  }
782  }
783 
784  if ($this->availability_enabled) {
785  $this->addAvailability();
786  }
787 
788  $this->addPreconditions();
789 
790  // learning progress
791  if ($this->learning_progress_enabled) {
792  $this->showLearningProgress($tpl);
793  }
794 
795  // notes section
796  if ($this->private_notes_enabled && !$ilSetting->get('disable_notes')) {
797  $html = $this->showNotesSection();
798  $tpl->setCurrentBlock("notes");
799  $tpl->setVariable("NOTES", $html);
801  }
802 
803  if (
804  isset($this->gui_object) &&
805  method_exists($this->gui_object, "getObject") &&
806  is_object($this->gui_object->getObject())
807  ) {
808  $this->addObjectSections();
809  }
810 
811  // render all sections
812  for ($i = 1; $i <= $this->sec_nr; $i++) {
813  if (isset($this->section[$i]["properties"])) {
814  // section properties
815  foreach ($this->section[$i]["properties"] as $property) {
816  if ($property["name"] != "") {
817  if (($property["link"] ?? "") == "") {
818  $tpl->setCurrentBlock("pv");
819  $tpl->setVariable("TXT_PROPERTY_VALUE", $property["value"]);
820  } else {
821  $tpl->setCurrentBlock("lpv");
822  $tpl->setVariable("TXT_PROPERTY_LVALUE", $property["value"]);
823  $tpl->setVariable("LINK_PROPERTY_VALUE", $property["link"]);
824  }
826  $tpl->setCurrentBlock("property_row");
827  $tpl->setVariable("TXT_PROPERTY", $property["name"]);
828  } else {
829  $tpl->setCurrentBlock("property_full_row");
830  $tpl->setVariable("TXT_PROPERTY_FULL_VALUE", $property["value"]);
831  }
833  }
834 
835  // section header
836  if ($this->section[$i]["hidden"] ?? false) {
837  $tpl->setVariable("SECTION_HIDDEN", " style=\"display:none;\"");
838  $tpl->setVariable("SECTION_ID", "hidable_" . $i);
839  } else {
840  $tpl->setVariable("SECTION_ID", $i);
841  }
842  $tpl->setVariable("TCLASS", $this->getTableClass());
843  $tpl->setVariable("TXT_SECTION", $this->section[$i]["title"]);
844  $tpl->setCurrentBlock("row");
846  }
847  }
848 
849  if (!is_null($this->mbox)) {
850  $tpl->setVariable("MBOX", $this->ui->renderer()->render([$this->mbox]));
851  }
852 
853  return $tpl->get();
854  }
addPreconditions()
Add preconditions.
setCurrentBlock(string $blockname=self::DEFAULT_BLOCK)
Sets the template to the given block.
addBlockFile(string $var, string $block, string $template_name, ?string $in_module=null)
overwrites ITX::addBlockFile
addButton(string $a_title, string $a_link, string $a_frame="", string $a_position="top", bool $a_primary=false)
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...
parseCurrentBlock(string $blockname=self::DEFAULT_BLOCK)
Parses the given block.
setFormAction(string $a_form_action)
get(string $part=self::DEFAULT_BLOCK)
Renders the given block and returns the html string.
static initjQuery(?ilGlobalTemplateInterface $a_tpl=null)
inits and adds the jQuery JS-File to the global or a passed template
showLearningProgress(ilTemplate $a_tpl)
touchBlock(string $blockname)
overwrites ITX::touchBlock.
ILIAS Repository HTML HTMLUtil $html
global $ilSetting
Definition: privfeed.php:31
ilGlobalPageTemplate $tpl
setVariable(string $variable, $value='')
Sets the given variable to the given value.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getMessageBox()

ilInfoScreenGUI::getMessageBox ( )

Definition at line 156 of file class.ilInfoScreenGUI.php.

References $mbox.

157  {
158  return $this->mbox;
159  }
ILIAS UI Component MessageBox MessageBox $mbox

◆ getRightColumnHTML()

ilInfoScreenGUI::getRightColumnHTML ( )
Returns
string
Exceptions
ilCtrlException

Definition at line 660 of file class.ilInfoScreenGUI.php.

References $ctrl, $html, $news_enabled, IL_COL_RIGHT, IL_SCREEN_SIDE, and setColumnSettings().

Referenced by showSummary().

660  : string
661  {
662  $ilCtrl = $this->ctrl;
663 
664  $html = "";
665  $column_gui = new ilColumnGUI("info", IL_COL_RIGHT);
666  $this->setColumnSettings($column_gui);
667 
668  if ($ilCtrl->getNextClass() == "ilcolumngui" &&
669  $column_gui->getCmdSide() == IL_COL_RIGHT &&
670  $column_gui->getScreenMode() == IL_SCREEN_SIDE) {
671  $html = $ilCtrl->forwardCommand($column_gui);
672  } elseif (!$ilCtrl->isAsynch() && $this->news_enabled) {
673  $html = $ilCtrl->getHTML($column_gui);
674  }
675 
676  return $html;
677  }
const IL_COL_RIGHT
setColumnSettings(ilColumnGUI $column_gui)
Set column settings.
Column user interface class.
ILIAS Repository HTML HTMLUtil $html
const IL_SCREEN_SIDE
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getTableClass()

ilInfoScreenGUI::getTableClass ( )

Definition at line 167 of file class.ilInfoScreenGUI.php.

References $table_class.

Referenced by getHTML().

167  : string
168  {
169  return $this->table_class;
170  }
+ Here is the caller graph for this function:

◆ getTabs()

ilInfoScreenGUI::getTabs ( ilTabsGUI  $tabs_gui)

Definition at line 1045 of file class.ilInfoScreenGUI.php.

References ilTabsGUI\addSubTabTarget(), and ILIAS\Repository\ctrl().

Referenced by setTabs().

1045  : void
1046  {
1047  $next_class = $this->ctrl->getNextClass($this);
1048  $force_active = ($next_class == "ilnotegui");
1049 
1050  $tabs_gui->addSubTabTarget(
1051  'summary',
1052  $this->ctrl->getLinkTarget($this, "showSummary"),
1053  array("showSummary", ""),
1054  get_class($this),
1055  "",
1056  $force_active
1057  );
1058  }
addSubTabTarget(string $a_text, string $a_link, $a_cmd="", $a_cmdClass="", string $a_frame="", bool $a_activate=false, bool $a_dir_text=false)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ hideFurtherSections()

ilInfoScreenGUI::hideFurtherSections ( bool  $a_add_toggle = true)

Definition at line 1062 of file class.ilInfoScreenGUI.php.

1062  : void
1063  {
1064  $this->hidden = true;
1065  $this->show_hidden_toggle = $a_add_toggle;
1066  }

◆ removeFormAction()

ilInfoScreenGUI::removeFormAction ( )

Definition at line 237 of file class.ilInfoScreenGUI.php.

237  : void
238  {
239  $this->form_action = "";
240  }

◆ saveProgress()

ilInfoScreenGUI::saveProgress ( bool  $redirect = true)

Definition at line 936 of file class.ilInfoScreenGUI.php.

References $user, ilObject\_lookupType(), ilLearningProgress\_tracProgress(), ilLPStatusWrapper\_updateStatus(), ILIAS\Repository\ctrl(), getContextObjId(), getContextRefId(), and ILIAS\Repository\lng().

936  : void
937  {
938  $ilUser = $this->user;
939 
940  // ensure a read event
942  $ilUser->getId(),
943  $this->getContextObjId(),
944  $this->getContextRefId(),
946  );
947 
948  $lp_marks = new ilLPMarks($this->getContextObjId(), $ilUser->getId());
949  $lp_marks->setCompleted((bool) $this->request->getLPEdit());
950  $lp_marks->update();
951 
952  ilLPStatusWrapper::_updateStatus($this->getContextObjId(), $ilUser->getId());
953 
954  $this->lng->loadLanguageModule('trac');
955  $this->tpl->setOnScreenMessage('success', $this->lng->txt('trac_updated_status'), true);
956 
957  if ($redirect) {
958  $this->ctrl->redirect($this, ""); // #14993
959  }
960  }
static _tracProgress(int $a_user_id, int $a_obj_id, int $a_ref_id, string $a_obj_type='')
static _lookupType(int $id, bool $reference=false)
static _updateStatus(int $a_obj_id, int $a_usr_id, ?object $a_obj=null, bool $a_percentage=false, bool $a_force_raise=false)
+ Here is the call graph for this function:

◆ setBlockProperty()

ilInfoScreenGUI::setBlockProperty ( string  $a_block_type,
string  $a_property,
string  $a_value 
)

This function is supposed to be used for block type specific properties, that should be passed to ilBlockGUI->setProperty.

Definition at line 212 of file class.ilInfoScreenGUI.php.

212  : void
213  {
214  $this->block_property[$a_block_type][$a_property] = $a_value;
215  }

◆ setCloseFormTag()

ilInfoScreenGUI::setCloseFormTag ( bool  $a_val)

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

694  : void
695  {
696  $this->close_form_tag = $a_val;
697  }

◆ setColumnSettings()

ilInfoScreenGUI::setColumnSettings ( ilColumnGUI  $column_gui)

Set column settings.

Definition at line 682 of file class.ilInfoScreenGUI.php.

References getAllBlockProperties(), ilColumnGUI\setAllBlockProperties(), ilColumnGUI\setEnableEdit(), and ilColumnGUI\setRepositoryMode().

Referenced by getCenterColumnHTML(), and getRightColumnHTML().

682  : void
683  {
684  $column_gui->setEnableEdit($this->news_editing);
685  $column_gui->setRepositoryMode(true);
686  $column_gui->setAllBlockProperties($this->getAllBlockProperties());
687  }
setRepositoryMode(bool $a_repositorymode)
setEnableEdit(bool $a_enableedit)
setAllBlockProperties(array $a_block_properties)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setContentObjType()

ilInfoScreenGUI::setContentObjType ( string  $contentObjType)

Definition at line 893 of file class.ilInfoScreenGUI.php.

References $contentObjType.

893  : void
894  {
895  $this->contentObjType = $contentObjType;
896  }

◆ setContextObjId()

ilInfoScreenGUI::setContextObjId ( int  $contextObjId)

Definition at line 879 of file class.ilInfoScreenGUI.php.

References $contextObjId.

879  : void
880  {
881  $this->contextObjId = $contextObjId;
882  }

◆ setContextRefId()

ilInfoScreenGUI::setContextRefId ( int  $contextRefId)

Definition at line 865 of file class.ilInfoScreenGUI.php.

References $contextRefId.

865  : void
866  {
867  $this->contextRefId = $contextRefId;
868  }

◆ setFormAction()

ilInfoScreenGUI::setFormAction ( string  $a_form_action)
Deprecated:

Definition at line 232 of file class.ilInfoScreenGUI.php.

Referenced by getHTML(), and ilCalendarAppointmentPresentationGUI\getModalHTML().

232  : void
233  {
234  $this->form_action = $a_form_action;
235  }
+ Here is the caller graph for this function:

◆ setMessageBox()

ilInfoScreenGUI::setMessageBox ( ILIAS\UI\Component\MessageBox\MessageBox  $a_val)

Definition at line 151 of file class.ilInfoScreenGUI.php.

151  : void
152  {
153  $this->mbox = $a_val;
154  }

◆ setOpenFormTag()

ilInfoScreenGUI::setOpenFormTag ( bool  $a_val)

Definition at line 689 of file class.ilInfoScreenGUI.php.

689  : void
690  {
691  $this->open_form_tag = $a_val;
692  }

◆ setTableClass()

ilInfoScreenGUI::setTableClass ( string  $a_val)

Definition at line 162 of file class.ilInfoScreenGUI.php.

162  : void
163  {
164  $this->table_class = $a_val;
165  }

◆ setTabs()

ilInfoScreenGUI::setTabs ( )

Definition at line 1040 of file class.ilInfoScreenGUI.php.

References getTabs().

Referenced by executeCommand().

1040  : void
1041  {
1042  $this->getTabs($this->tabs_gui);
1043  }
getTabs(ilTabsGUI $tabs_gui)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ showLDAPRoleGroupMappingInfo()

ilInfoScreenGUI::showLDAPRoleGroupMappingInfo ( string  $a_section = '')
Parameters
string$a_sectionsection name. Leave empty to place this info string inside a section

Definition at line 1020 of file class.ilInfoScreenGUI.php.

References ilLDAPRoleGroupMapping\_getInstance(), addProperty(), addSection(), and ILIAS\Repository\lng().

1020  : void
1021  {
1022  if (strlen($a_section)) {
1023  $this->addSection($a_section);
1024  }
1025  $ldap_mapping = ilLDAPRoleGroupMapping::_getInstance();
1026  if ($infos = $ldap_mapping->getInfoStrings($this->gui_object->getObject()->getId())) {
1027  $info_combined = '<div style="color:green;">';
1028  $counter = 0;
1029  foreach ($infos as $info_string) {
1030  if ($counter++) {
1031  $info_combined .= '<br />';
1032  }
1033  $info_combined .= $info_string;
1034  }
1035  $info_combined .= '</div>';
1036  $this->addProperty($this->lng->txt('applications'), $info_combined);
1037  }
1038  }
addProperty(string $a_name, string $a_value, string $a_link="")
add a property to current section
static _getInstance()
Get singleton instance of this class.
addSection(string $a_title)
+ Here is the call graph for this function:

◆ showLearningProgress()

ilInfoScreenGUI::showLearningProgress ( ilTemplate  $a_tpl)
Parameters
ilTemplate$a_tpl
Exceptions
ilDateTimeException

Definition at line 902 of file class.ilInfoScreenGUI.php.

References $rbacsystem, $user, ilObjUserTracking\_enabledLearningProgress(), ANONYMOUS_USER_ID, ilRbacSystem\checkAccess(), getContextObjId(), ilObjectLP\getInstance(), ILIAS\Repository\lng(), ilLPObjSettings\LP_MODE_MANUAL, ilTemplate\parseCurrentBlock(), and HTML_Template_IT\setVariable().

Referenced by getHTML().

902  : void
903  {
904  return;
905 
906  $ilUser = $this->user;
908 
909  if (!$rbacsystem->checkAccess('read', $this->getContextRefId())) {
910  return;
911  }
912  if ($ilUser->getId() == ANONYMOUS_USER_ID) {
913  return;
914  }
915 
917  return;
918  }
919 
920  $olp = ilObjectLP::getInstance($this->getContextObjId());
921  if ($olp->getCurrentMode() != ilLPObjSettings::LP_MODE_MANUAL) {
922  return;
923  }
924 
925  $this->lng->loadLanguageModule('trac');
926 
927  // section header
928  // $a_tpl->setCurrentBlock("header_row");
929  $a_tpl->setVariable(
930  "TXT_SECTION",
931  $this->lng->txt('learning_progress')
932  );
933  $a_tpl->parseCurrentBlock();
934  }
parseCurrentBlock(string $part=ilGlobalTemplateInterface::DEFAULT_BLOCK)
const ANONYMOUS_USER_ID
Definition: constants.php:27
checkAccess(string $a_operations, int $a_ref_id, string $a_type="")
checkAccess represents the main method of the RBAC-system in ILIAS3 developers want to use With this ...
setVariable($variable, $value='')
Sets a variable value.
Definition: IT.php:544
static getInstance(int $obj_id)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ showNotesSection()

ilInfoScreenGUI::showNotesSection ( )
Returns
string
Exceptions
ilCtrlException

Definition at line 967 of file class.ilInfoScreenGUI.php.

References $access, $DIC, $html, $ilSetting, $ref_id, $settings, and ILIAS\Repository\ctrl().

Referenced by executeCommand(), and getHTML().

967  : string
968  {
969  global $DIC;
970 
971  $ilAccess = $this->access;
973  $notes_gui = $DIC->notes()->gui();
974  $notes_gui->initJavascript();
975  $comments_gui = $notes_gui->getCommentsGUI(
976  $this->gui_object->getObject()->getId(),
977  0,
978  $this->gui_object->getObject()->getType()
979  );
980 
981  $next_class = $this->ctrl->getNextClass($this);
982  $comments_gui->setUseObjectTitleHeader(false);
983 
984  // global switch
985  if ($ilSetting->get("disable_comments")) {
986  return "";
987  } else {
988  $ref_id = $this->gui_object->getObject()->getRefId();
989  $has_write = $ilAccess->checkAccess("write", "", $ref_id);
990 
991  if ($has_write && $ilSetting->get("comments_del_tutor", "1")) {
992  $comments_gui->enablePublicNotesDeletion();
993  }
994 
995  /* should probably be discussed further
996  for now this will only work properly with comments settings
997  (see ilNoteGUI constructor)
998  */
999  if ($has_write ||
1000  $ilAccess->checkAccess("edit_permissions", "", $ref_id)) {
1001  $comments_gui->enableCommentsSettings();
1002  }
1003  }
1004 
1005  /* moved to action menu
1006  $notes_gui->enablePrivateNotes();
1007  */
1008  if ($next_class === strtolower(ilCommentGUI::class)) {
1009  $html = $this->ctrl->forwardCommand($comments_gui);
1010  } else {
1011  $html = $comments_gui->getListHTML();
1012  }
1013 
1014  return $html;
1015  }
ilAccessHandler $access
$ref_id
Definition: ltiauth.php:65
global $DIC
Definition: shib_login.php:22
ILIAS Repository HTML HTMLUtil $html
global $ilSetting
Definition: privfeed.php:31
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ showSummary()

ilInfoScreenGUI::showSummary ( )
Exceptions
ilCtrlException
ilDatabaseException
ilDateTimeException
ilObjectNotFoundException

Definition at line 611 of file class.ilInfoScreenGUI.php.

References $tpl, getCenterColumnHTML(), getRightColumnHTML(), ilGlobalPageTemplate\setContent(), and ilGlobalPageTemplate\setRightContent().

Referenced by executeCommand().

611  : void
612  {
613  $tpl = $this->tpl;
614 
617  }
setRightContent(string $a_html)
Sets content of right column.
ilGlobalPageTemplate $tpl
setContent(string $a_html)
Sets content for standard template.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $access

ilAccessHandler ilInfoScreenGUI::$access
protected

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

Referenced by buildPublicAccessExportButton(), and showNotesSection().

◆ $availability_enabled

bool ilInfoScreenGUI::$availability_enabled = true
protected

Definition at line 61 of file class.ilInfoScreenGUI.php.

◆ $block_property

array ilInfoScreenGUI::$block_property = []
protected

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

Referenced by getAllBlockProperties().

◆ $booking_enabled

bool ilInfoScreenGUI::$booking_enabled = false
protected

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

◆ $close_form_tag

bool ilInfoScreenGUI::$close_form_tag = true

Definition at line 55 of file class.ilInfoScreenGUI.php.

◆ $contentObjType

string ilInfoScreenGUI::$contentObjType = null
protected

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

Referenced by getContentObjType(), and setContentObjType().

◆ $contextObjId

int ilInfoScreenGUI::$contextObjId = null
protected

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

Referenced by getContextObjId(), and setContextObjId().

◆ $contextRefId

int ilInfoScreenGUI::$contextRefId = null
protected

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

Referenced by getContextRefId(), and setContextRefId().

◆ $ctrl

ilCtrl ilInfoScreenGUI::$ctrl

◆ $data_factory

DataFactory ilInfoScreenGUI::$data_factory
protected

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

◆ $feedback_enabled

bool ilInfoScreenGUI::$feedback_enabled = false
protected

Definition at line 70 of file class.ilInfoScreenGUI.php.

◆ $form_action

string ilInfoScreenGUI::$form_action

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

◆ $gui_object

object ilInfoScreenGUI::$gui_object

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

◆ $hidden

bool ilInfoScreenGUI::$hidden = false
protected

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

Referenced by addSection().

◆ $hiddenelements

array ilInfoScreenGUI::$hiddenelements = array()

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

◆ $html

ILIAS Repository HTML HTMLUtil ilInfoScreenGUI::$html
protected

◆ $learning_progress_enabled

bool ilInfoScreenGUI::$learning_progress_enabled = false
protected

Definition at line 71 of file class.ilInfoScreenGUI.php.

◆ $lng

◆ $mbox

ILIAS UI Component MessageBox MessageBox ilInfoScreenGUI::$mbox = null
protected

Definition at line 37 of file class.ilInfoScreenGUI.php.

Referenced by getMessageBox().

◆ $metadata

Metadata ilInfoScreenGUI::$metadata
protected

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

◆ $news_editing

bool ilInfoScreenGUI::$news_editing = false
protected

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

◆ $news_enabled

bool ilInfoScreenGUI::$news_enabled = false
protected

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

Referenced by getRightColumnHTML().

◆ $open_form_tag

bool ilInfoScreenGUI::$open_form_tag = true

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

◆ $private_notes_enabled

bool ilInfoScreenGUI::$private_notes_enabled = false
protected

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

◆ $rbacsystem

ilRbacSystem ilInfoScreenGUI::$rbacsystem
protected

Definition at line 39 of file class.ilInfoScreenGUI.php.

Referenced by showLearningProgress().

◆ $request

StandardGUIRequest ilInfoScreenGUI::$request
protected

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

◆ $sec_nr

int ilInfoScreenGUI::$sec_nr = 0
protected

Definition at line 67 of file class.ilInfoScreenGUI.php.

Referenced by addProperty(), addPropertyTextinput(), addSection(), and getHTML().

◆ $section

array ilInfoScreenGUI::$section = []
protected

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

◆ $settings

ilSetting ilInfoScreenGUI::$settings
protected

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

Referenced by getHTML(), and showNotesSection().

◆ $show_hidden_toggle

bool ilInfoScreenGUI::$show_hidden_toggle = false
protected

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

◆ $table_class

string ilInfoScreenGUI::$table_class = "il_InfoScreen"

Definition at line 53 of file class.ilInfoScreenGUI.php.

Referenced by getTableClass().

◆ $tabs_gui

ilTabsGUI ilInfoScreenGUI::$tabs_gui
protected

Definition at line 38 of file class.ilInfoScreenGUI.php.

◆ $top_buttons

array ilInfoScreenGUI::$top_buttons = array()

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

◆ $top_formbuttons

array ilInfoScreenGUI::$top_formbuttons = array()

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

◆ $tpl

ilGlobalPageTemplate ilInfoScreenGUI::$tpl
protected

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

Referenced by executeCommand(), and showSummary().

◆ $tree

ilTree ilInfoScreenGUI::$tree
protected

◆ $ui

ILIAS DI UIServices ilInfoScreenGUI::$ui
protected

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

◆ $user

ilObjUser ilInfoScreenGUI::$user
protected

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