2 require_once(
'./Services/Form/classes/class.ilPropertyFormGUI.php');
63 $this->obj_orgu->update();
71 protected function initForm() {
72 $this->
setFormAction($this->ctrl->getFormAction($this->parent_gui));
73 $this->
setTitle($this->lng->txt(
'orgu_settings'));
77 $item->setValue($this->obj_orgu->getTitle());
81 $item->
setValue($this->obj_orgu->getDescription());
85 $item->setTitle($this->lng->txt(
'orgu_type'));
90 foreach ($types as $type) {
91 $options[$type->getId()] = $type->getTitle();
96 $item->setValue($this->obj_orgu->getOrgUnitTypeId());
100 $item->setTitle($this->lng->txt(
'ext_id'));
104 $item->
setValue($this->obj_orgu->getImportId());
120 $this->obj_orgu->setOrgUnitTypeId($this->
getInput(
'orgu_type'));
121 $this->obj_orgu->setImportId($this->
getInput(
'ext_id'));
122 $this->obj_orgu->setTitle($this->
getInput(
'title'));
123 $this->obj_orgu->setDescription($this->
getInput(
'description'));
131 $translations = $this->obj_orgu->getTranslations();
132 $lang_code_default =
'';
133 $lang_codes = array();
134 foreach ($translations[
'Fobject'] as $translation) {
135 if ($translation[
'lang_default']) {
136 $lang_code_default = $translation[
'lang'];
138 $lang_codes[] = $translation[
'lang'];
140 $lang_code = (in_array($this->user->getLanguage(), $lang_codes)) ? $this->user->getLanguage() : $lang_code_default;
141 $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.
if(!is_array($argv)) $options
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.