4 include_once(
'./Services/Table/classes/class.ilTable2GUI.php');
15 public function __construct($a_parent_obj, $a_parent_cmd, array &$a_data, $a_view, $a_by_location =
false)
19 $this->
setId(
"pdmng");
23 $this->
addColumn($this->lng->txt(
"type"),
'type_caption',
'1%');
24 $this->
addColumn($this->lng->txt(
"title"),
'title',
'44%');
25 $this->
addColumn($this->lng->txt(
"container"),
'container',
'50%');
29 $this->
setRowTemplate(
"tpl.pd_manage_row.html",
"Services/PersonalDesktop");
31 $this->
setFormAction($ilCtrl->getFormAction($a_parent_obj, $a_parent_cmd));
35 $this->
setTitle($this->lng->txt(
"pd_my_offers"));
36 $this->
addMultiCommand(
'confirmRemove', $this->lng->txt(
'unsubscribe'));
40 $this->
setTitle($this->lng->txt(
"pd_my_memberships"));
41 $this->
addMultiCommand(
'confirmRemove', $this->lng->txt(
'crs_unsubscribe'));
47 $root = $tree->getNodeData(ROOT_FOLDER_ID);
48 $root = $root[
"title"];
51 $root = $this->lng->txt(
"repository");
54 foreach($a_data as $idx => $item)
56 if(!$item[
"parent_ref"])
64 $a_data[$idx][
"last_admin"] =
false;
70 include_once
"Modules/Course/classes/class.ilCourseParticipants.php";
75 include_once
"Modules/Group/classes/class.ilGroupParticipants.php";
84 $a_data[$idx][
"last_admin"] = $members->isLastAdmin($ilUser->getId());
87 $a_data[$idx][
"type_caption"] = $this->lng->txt(
"obj_".$item[
"type"]);
90 if ($tree->getRootId() != $item[
"parent_ref"])
96 $a_data[$idx][
"container"] = $root;
106 if($a_set[
"last_admin"])
108 $this->tpl->setCurrentBlock(
"warning_bl");
109 $this->tpl->setVariable(
"TXT_WARNING", $this->lng->txt(
'pd_min_one_admin'));
110 $this->tpl->parseCurrentBlock();
112 $this->tpl->setVariable(
"CHK_DISABLED",
' disabled="disabled"');
115 $this->tpl->setVariable(
"VAL_REF_ID", $a_set[
"ref_id"]);
116 $this->tpl->setVariable(
"TXT_TITLE", $a_set[
"title"]);
117 $this->tpl->setVariable(
"TXT_DESCRIPTION", $a_set[
"desc"]);
119 $this->tpl->setVariable(
"TXT_TYPE", $this->lng->txt(
"icon").
" ".$a_set[
"type_caption"]);
120 $this->tpl->setVariable(
"TXT_CONTAINER", $a_set[
"container"]);