4require_once
"./Services/Table/classes/class.ilTable2GUI.php";
20 function __construct($a_parent_obj, $a_parent_cmd, $a_params = array())
25 $this->params = $a_params;
28 parent::__construct($a_parent_obj, $a_parent_cmd);
30 $this->
setRowTemplate(
"tpl.lang_items_row.html",
"Services/Language");
38 if ($compare == $this->params[
'lang_key'])
40 $compare_note =
" ".
$lng->txt(
"language_default_entries");
43 $this->
addColumn(ucfirst(
$lng->txt(
"module")),
"module",
"10em");
44 $this->
addColumn(ucfirst(
$lng->txt(
"identifier")),
"topic",
"10em");
45 $this->
addColumn($lng->txt(
"meta_l_".$this->params[
'lang_key']),
"translation");
46 $this->
addColumn($lng->txt(
"meta_l_".$compare).$compare_note,
"default");
60 $data[
'name'] = str_replace(
'.',
'_POSTDOT_',
$data[
'name']);
61 $data[
'name'] = str_replace(
' ',
'_POSTSPACE_',
$data[
'name']);
63 if ($this->params[
'langmode'])
65 $this->tpl->setCurrentBlock(
'comment');
69 $this->tpl->setVariable(
"COM_SIZE", $this->commentsize);
70 $this->tpl->setVariable(
"COM_MAX", 250);
71 $this->tpl->setVariable(
"TXT_COMMENT",
$lng->txt(
'comment'));
72 $this->tpl->parseCurrentBlock();
76 $this->tpl->setCurrentBlock(
'hidden_comment');
79 $this->tpl->parseCurrentBlock();
82 $this->tpl->setVariable(
"T_ROWS", ceil(strlen(
$data[
"translation"]) / $this->inputsize));
83 $this->tpl->setVariable(
"T_SIZE", $this->inputsize);
105 include_once(
"./Services/Form/classes/class.ilTextInputGUI.php");
107 $ti->setParent($this->parent_obj);
108 $ti->setMaxLength(64);
111 $ti->readFromSession();
117 foreach ($modules as $mod)
122 include_once(
"./Services/Form/classes/class.ilSelectInputGUI.php");
124 $si->setParent($this->parent_obj);
127 $si->readFromSession();
128 if (!
$si->getValue())
130 $si->setValue(
'administration');
134 include_once(
"./Services/Form/classes/class.ilTextInputGUI.php");
136 $ti->setParent($this->parent_obj);
137 $ti->setMaxLength(64);
140 $ti->readFromSession();
145 $options[
"changed"] =
$lng->txt(
"language_scope_local");
146 if ($this->params[
'langmode'])
150 $options[
"unchanged"] =
$lng->txt(
"language_scope_unchanged");
152 $options[
"different"] =
$lng->txt(
"language_scope_different");
153 $options[
"commented"] =
$lng->txt(
"language_scope_commented");
154 if ($this->params[
'langmode'])
156 $options[
"dbremarks"] =
$lng->txt(
"language_scope_dbremarks");
158 $options[
"conflicts"] =
$lng->txt(
"language_scope_conflicts");
160 include_once(
"./Services/Form/classes/class.ilSelectInputGUI.php");
162 $si->setParent($this->parent_obj);
165 $si->readFromSession();
166 if (!
$si->getValue())
168 $si->setValue(
'all');
174 $langlist =
$lng->getInstalledLanguages();
175 foreach ($langlist as $lang_key)
180 include_once(
"./Services/Form/classes/class.ilSelectInputGUI.php");
182 $si->setParent($this->parent_obj);
185 $si->readFromSession();
186 if (!
$si->getValue())
188 $si->setValue($lng->getDefaultLanguage());
An exception for terminatinating execution or to throw for unit testing.
__construct($a_parent_obj, $a_parent_cmd, $a_params=array())
Constructor.
fillRow($data)
Fill a single data row.
static _isPageTranslation()
Check if the current request is a page translation.
static _getModules($a_lang_key)
Get all modules of a language.
setDisableFilterHiding($a_val=true)
Set disable filter hiding.
addColumn($a_text, $a_sort_field="", $a_width="", $a_is_checkbox_action_column=false, $a_class="", $a_tooltip="", $a_tooltip_with_html=false)
Add a column to the header.
setRowTemplate($a_template, $a_template_dir="")
Set row template.
getFilterItemByPostVar($a_post_var)
addFilterItem($a_input_item, $a_optional=false)
Add filter item.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
addCommandButton($a_cmd, $a_text, $a_onclick='', $a_id="", $a_class=null)
Add Command button.
This class represents a text property in a property form.
static prepareFormOutput($a_str, $a_strip=false)
prepares string output for html forms @access public
if(!is_array($argv)) $options