24 include_once(
"Services/Table/classes/class.ilTable2GUI.php");
25 include_once(
"Services/Component/classes/class.ilComponent.php");
45 $this->mode = $a_mode;
51 $this->
addColumn($lng->txt(
"cmps_module"));
52 $this->
addColumn($lng->txt(
"cmps_rep_object"));
56 $this->
addColumn($lng->txt(
"cmps_service"));
58 $this->
addColumn($lng->txt(
"cmps_plugin_slot"));
62 "Services/Component");
72 $this->
setTitle($lng->txt(
"cmps_modules"));
76 $this->
setTitle($lng->txt(
"cmps_services"));
87 include_once(
"./Services/Component/classes/class.ilModule.php");
93 include_once(
"./Services/Component/classes/class.ilService.php");
110 foreach ($plugin_slots as $slot)
112 $this->tpl->setCurrentBlock(
"slot");
113 $this->tpl->setVariable(
"SLOT_NAME", $slot[
"name"]);
114 $this->tpl->setVariable(
"SLOT_ID", $slot[
"id"]);
115 $this->tpl->setVariable(
"TXT_DIR", $lng->txt(
"cmps_dir"));
116 $this->tpl->setVariable(
"SLOT_DIR", $slot[
"dir_pres"]);
117 $this->tpl->setVariable(
"TXT_LANG_PREFIX", $lng->txt(
"cmps_lang_prefix"));
118 $this->tpl->setVariable(
"LANG_PREFIX", $slot[
"lang_prefix"]);
120 $ilCtrl->setParameter($this->parent_obj,
"ctype", $this->mode);
121 $ilCtrl->setParameter($this->parent_obj,
"cname", $a_set[
"subdir"]);
122 $ilCtrl->setParameter($this->parent_obj,
"slot_id", $slot[
"id"]);
123 $this->tpl->setVariable(
"HREF_SHOW_SLOT",
124 $ilCtrl->getLinkTarget($this->parent_obj,
"showPluginSlot"));
125 $this->tpl->setVariable(
"TXT_SHOW_SLOT", $lng->txt(
"cmps_show_details"));
126 $this->tpl->parseCurrentBlock();
134 $objDefinition->getRepositoryObjectTypesForComponent(
IL_COMP_MODULE, $a_set[
"subdir"]);
136 foreach ($rep_types as $rt)
139 if ($rt[
"grp"] !=
"")
141 $this->tpl->setCurrentBlock(
"group");
142 $this->tpl->setVariable(
"TXT_GROUP", $lng->txt(
"cmps_group"));
143 $gi = $objDefinition->getGroup($rt[
"grp"]);
144 $this->tpl->setVariable(
"VAL_GROUP", $gi[
"name"]);
145 $this->tpl->setVariable(
"VAL_GROUP_ID", $rt[
"grp"]);
146 $this->tpl->parseCurrentBlock();
149 $this->tpl->setCurrentBlock(
"rep_object");
150 $this->tpl->setVariable(
"TXT_REP_OBJECT",
152 $this->tpl->setVariable(
"TXT_REP_OBJECT_ID",
154 $this->tpl->setVariable(
"IMG_REP_OBJECT",
158 $this->tpl->setVariable(
"TXT_ADD_NEW_POS",
159 $lng->txt(
"cmps_add_new_rank"));
160 $this->tpl->setVariable(
"VAR_POS",
161 "obj_pos[".$rt[
"id"].
"]");
162 $pos = ($ilSetting->get(
"obj_add_new_pos_".$rt[
"id"]) > 0)
163 ? $ilSetting->get(
"obj_add_new_pos_".$rt[
"id"])
164 : $rt[
"default_pos"];
165 $this->tpl->setVariable(
"VAL_POS",
169 $this->tpl->setVariable(
"TXT_DISABLE_CREATION",
170 $lng->txt(
"cmps_disable_creation"));
171 $this->tpl->setVariable(
"VAR_DISABLE_CREATION",
172 "obj_dis_creation[".$rt[
"id"].
"]");
173 if ($ilSetting->get(
"obj_dis_creation_".$rt[
"id"]))
175 $this->tpl->setVariable(
"CHECKED_DISABLE_CREATION",
176 ' checked="checked" ');
179 $this->tpl->parseCurrentBlock();
181 $this->tpl->setCurrentBlock(
"rep_object_td");
182 if (count($rep_types) == 0)
184 $this->tpl->setVariable(
"DUMMY",
" ");
186 $this->tpl->parseCurrentBlock();
189 $this->tpl->setVariable(
"TXT_MODULE_NAME", $a_set[
"subdir"]);