5 include_once(
"Services/Table/classes/class.ilTable2GUI.php");
19 $a_c_type, $a_c_name, $a_slot_id)
23 include_once(
"./Services/Component/classes/class.ilPluginSlot.php");
24 $this->slot =
new ilPluginSlot($a_c_type, $a_c_name, $a_slot_id);
29 $this->
addColumn($lng->txt(
"cmps_plugin"));
30 $this->
addColumn($lng->txt(
"cmps_basic_files"));
31 $this->
addColumn($lng->txt(
"cmps_languages"));
32 $this->
addColumn($lng->txt(
"cmps_database"));
37 "Services/Component");
45 $this->
setTitle($lng->txt(
"cmps_plugins"));
53 $plugins = $this->slot->getPluginsInformation();
66 $ilCtrl->setParameter($this->parent_obj,
"ctype",
$_GET[
"ctype"]);
67 $ilCtrl->setParameter($this->parent_obj,
"cname",
$_GET[
"cname"]);
68 $ilCtrl->setParameter($this->parent_obj,
"slot_id",
$_GET[
"slot_id"]);
69 $ilCtrl->setParameter($this->parent_obj,
"pname", $a_set[
"name"]);
78 include_once(
"./Services/Component/classes/class.ilPluginDBUpdate.php");
80 $_GET[
"slot_id"], $a_set[
"name"], $ilDB,
true,
"");
95 $this->tpl->setCurrentBlock(
"db_versions");
96 $this->tpl->setVariable(
"TXT_CURRENT_VERSION",
97 $lng->txt(
"cmps_current_version"));
98 $this->tpl->setVariable(
"VAL_CURRENT_VERSION",
99 $dbupdate->getCurrentVersion());
100 $this->tpl->setVariable(
"TXT_FILE_VERSION",
101 $lng->txt(
"cmps_file_version"));
102 $this->tpl->setVariable(
"VAL_FILE_VERSION",
103 $dbupdate->getFileVersion());
104 $this->tpl->parseCurrentBlock();
106 $this->tpl->setCurrentBlock(
"db_update");
107 $this->tpl->setVariable(
"DB_UPDATE_FILE",
112 $this->tpl->setCurrentBlock(
"db_update");
113 $this->tpl->setVariable(
"DB_UPDATE_FILE",
114 $lng->txt(
"cmps_no_db_update_file_available"));
116 $this->tpl->parseCurrentBlock();
121 $a_set[
"name"].
"/lang");
122 if (count($langs) == 0)
124 $this->tpl->setCurrentBlock(
"lang");
125 $this->tpl->setVariable(
"VAL_LANG_FILE",
126 $lng->txt(
"cmps_no_language_file_available"));
127 $this->tpl->parseCurrentBlock();
129 foreach($langs as
$lang)
131 $this->tpl->setCurrentBlock(
"lang");
132 $this->tpl->setVariable(
"VAL_LANG_FILE",
134 $this->tpl->parseCurrentBlock();
138 if ($a_set[
"activation_possible"])
140 $this->tpl->setCurrentBlock(
"activate");
141 $this->tpl->setVariable(
"HREF_ACTIVATE",
142 $ilCtrl->getLinkTarget($this->parent_obj,
"activatePlugin"));
143 $this->tpl->setVariable(
"TXT_ACTIVATE",
144 $lng->txt(
"cmps_activate"));
145 $this->tpl->parseCurrentBlock();
149 if ($a_set[
"is_active"])
152 $this->tpl->setCurrentBlock(
"deactivate");
153 $this->tpl->setVariable(
"HREF_DEACTIVATE",
154 $ilCtrl->getLinkTarget($this->parent_obj,
"deactivatePlugin"));
155 $this->tpl->setVariable(
"TXT_DEACTIVATE",
156 $lng->txt(
"cmps_deactivate"));
157 $this->tpl->parseCurrentBlock();
160 if (count($langs) > 0)
162 $this->tpl->setCurrentBlock(
"refresh_langs");
163 $this->tpl->setVariable(
"HREF_REFRESH_LANGS",
164 $ilCtrl->getLinkTarget($this->parent_obj,
"refreshLanguages"));
165 $this->tpl->setVariable(
"TXT_REFRESH_LANGS",
166 $lng->txt(
"cmps_refresh"));
167 $this->tpl->parseCurrentBlock();
174 $this->tpl->setCurrentBlock(
"configure");
175 $this->tpl->setVariable(
"HREF_CONFIGURE",
177 $this->tpl->setVariable(
"TXT_CONFIGURE",
178 $lng->txt(
"cmps_configure"));
179 $this->tpl->parseCurrentBlock();
184 if ($a_set[
"needs_update"])
186 $this->tpl->setCurrentBlock(
"update");
187 $this->tpl->setVariable(
"HREF_UPDATE",
188 $ilCtrl->getLinkTarget($this->parent_obj,
"updatePlugin"));
189 $this->tpl->setVariable(
"TXT_UPDATE",
190 $lng->txt(
"cmps_update"));
191 $this->tpl->parseCurrentBlock();
194 if (strlen($a_set[
"responsible"]))
196 $responsibles = explode(
'/', $a_set[
"responsible_mail"]);
197 $first_handled =
false;
198 foreach($responsibles as $responsible)
200 if(!strlen($responsible = trim($responsible)))
207 $this->tpl->touchBlock(
'plugin_responsible_sep');
210 $this->tpl->setCurrentBlock(
"plugin_responsible");
211 $this->tpl->setVariable(
"VAL_PLUGIN_RESPONSIBLE_MAIL", $responsible);
212 $this->tpl->parseCurrentBlock();
213 $first_handled =
true;
216 $this->tpl->setCurrentBlock(
"responsible_mail");
217 $this->tpl->parseCurrentBlock();
219 $this->tpl->setCurrentBlock(
"responsible");
220 $this->tpl->setVariable(
"TXT_RESPONSIBLE", $lng->txt(
"cmps_responsible"));
221 $this->tpl->setVariable(
"VAL_PLUGIN_RESPONSIBLE", $a_set[
"responsible"]);
222 $this->tpl->parseCurrentBlock();
225 $this->tpl->setVariable(
"VAL_PLUGIN_NAME", $a_set[
"name"]);
226 $this->tpl->setVariable(
"VAL_PLUGIN_ID", $a_set[
"id"]);
227 $this->tpl->setVariable(
"TXT_PLUGIN_NAME", $lng->txt(
"cmps_name"));
228 $this->tpl->setVariable(
"TXT_PLUGIN_ID", $lng->txt(
"cmps_id"));
229 $this->tpl->setVariable(
"TXT_PLUGIN_VERSION", $lng->txt(
"cmps_version"));
230 $this->tpl->setVariable(
"TXT_PHP_FILE",
"plugin.php");
231 $this->tpl->setVariable(
"TXT_CLASS_FILE", $lng->txt(
"cmps_class_file"));
232 $this->tpl->setVariable(
"VAL_CLASS_FILE", $a_set[
"class_file"]);
233 $this->tpl->setVariable(
"TXT_VERSION", $lng->txt(
"cmps_version"));
234 $this->tpl->setVariable(
"VAL_PLUGIN_VERSION", $a_set[
"version"]);
235 $this->tpl->setVariable(
"TXT_ILIAS_MIN", $lng->txt(
"cmps_ilias_min_version"));
236 $this->tpl->setVariable(
"VAL_ILIAS_MIN", $a_set[
"ilias_min_version"]);
237 $this->tpl->setVariable(
"TXT_ILIAS_MAX", $lng->txt(
"cmps_ilias_max_version"));
238 $this->tpl->setVariable(
"VAL_ILIAS_MAX", $a_set[
"ilias_max_version"]);
239 $this->tpl->setVariable(
"TXT_STATUS", $lng->txt(
"cmps_status"));
241 if ($a_set[
"is_active"])
243 $this->tpl->setVariable(
"VAL_STATUS", $lng->txt(
"cmps_active"));
247 $r = ($a_set[
"inactive_reason"] !=
"")
248 ?
" (".$a_set[
"inactive_reason"].
")"
251 $this->tpl->setVariable(
"VAL_STATUS", $lng->txt(
"cmps_inactive").$r);
254 if ($a_set[
"plugin_php_file_status"])
256 $this->tpl->setVariable(
"VAL_PLUGIN_PHP_FILE_STATUS", $lng->txt(
"cmps_available"));
260 $this->tpl->setVariable(
"VAL_PLUGIN_PHP_FILE_STATUS", $lng->txt(
"cmps_missing"));
262 if ($a_set[
"class_file_status"])
264 $this->tpl->setVariable(
"VAL_CLASS_FILE_STATUS", $lng->txt(
"cmps_available"));
268 $this->tpl->setVariable(
"VAL_CLASS_FILE_STATUS", $lng->txt(
"cmps_missing"));