69 $this->obj_orgu->update();
77 protected function initForm()
79 $this->
setFormAction($this->ctrl->getFormAction($this->parent_gui));
80 $this->
setTitle($this->lng->txt(
'orgu_settings'));
84 $item->setValue($this->obj_orgu->getTitle());
88 $item->
setValue($this->obj_orgu->getDescription());
92 $item->setTitle($this->lng->txt(
'orgu_type'));
97 foreach ($types as
$type) {
98 $options[$type->getId()] = $type->getTitle();
103 $item->setValue($this->obj_orgu->getOrgUnitTypeId());
107 $item->setTitle($this->lng->txt(
'ext_id'));
111 $item->
setValue($this->obj_orgu->getImportId());
128 $this->obj_orgu->setOrgUnitTypeId($this->
getInput(
'orgu_type'));
129 $this->obj_orgu->setImportId($this->
getInput(
'ext_id'));
130 $this->obj_orgu->setTitle($this->
getInput(
'title'));
131 $this->obj_orgu->setDescription($this->
getInput(
'description'));
140 $translations = $this->obj_orgu->getTranslations();
141 $lang_code_default =
'';
142 $lang_codes = array();
143 foreach ($translations[
'Fobject'] as $translation) {
144 if ($translation[
'lang_default']) {
145 $lang_code_default = $translation[
'lang'];
147 $lang_codes[] = $translation[
'lang'];
149 $lang_code = (in_array($this->
user->getLanguage(), $lang_codes)) ? $this->
user->getLanguage() : $lang_code_default;
150 $this->obj_orgu->updateTranslation($this->
getInput(
'title'), $this->
getInput(
'description'), $lang_code, 0);
setValue($a_value)
Set Value.
static getAllTypes()
Get array of all instances of ilOrgUnitType objects.
This class represents a text property in a property form.
This class represents a text area property in a property form.
setValue($a_value)
Set Value.