27 $opt = parent::buildFieldCreationInput($dcl, $mode);
30 $opt->addSubItem($selection_options);
33 $this->
lng->txt(
'dcl_selection_type'),
34 'prop_' . static::PROP_SELECTION_TYPE
42 $selection_type->addOption($option_1);
48 $selection_type->addOption($option_2);
54 $selection_type->addOption($option_3);
68 switch ($this->
getField()->getProperty(static::PROP_SELECTION_TYPE)) {
75 $input->setHeight(100);
76 $input->setHeightUnit(
'%; max-height: 150px');
77 $input->setWidth(100);
78 $input->setWidthUnit(
'%');
81 foreach ($options as $opt) {
82 $array[$opt->getOptId()] = $opt->getValue();
84 $input->setOptions($array);
89 foreach ($options as $opt) {
90 $array[$opt->getOptId()] = $opt->getValue();
92 $input->setOptions(array(
"" => $this->
lng->txt(
'dcl_please_select')) + $array);
97 foreach ($options as $opt) {
98 $input->addOption(
new ilRadioOption($opt->getValue(), $opt->getOptId()));
100 $input->setValue(array_keys($options)[0]);
122 $array = array(
'' => $this->
lng->txt(
'dcl_all_entries'));
123 foreach ($options as $opt) {
124 $array[$opt->getOptId()] = $opt->getValue();
127 $array[
'none'] = $this->
lng->txt(
'dcl_no_entry');
129 $input->setOptions($array);
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
buildFieldCreationInput(ilObjDataCollection $dcl, string $mode='create')
const SELECTION_TYPE_SINGLE
const SELECTION_TYPE_MULTI
getFilterInputFieldValue(ilTableFilterItem $input)
getInputField(ilPropertyFormGUI $form, ?int $record_id=null)
Returns field-input.
addFilterInputFieldToTable(ilTable2GUI $table)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setupInputField(ilFormPropertyGUI $input, ilDclBaseFieldModel $field)
Sets basic settings on field-input.
addFilterItemByMetaType(string $id, int $type=self::FILTER_TEXT, bool $a_optional=false, string $caption="")
Add filter by standard type.
const SELECTION_TYPE_COMBOBOX
static getAllForField(int $field_id)
setupFilterInputField(?ilTableFilterItem $input)
Set basic settings for filter-input-gui.
getField()
Return BaseFieldModel.
const PROP_SELECTION_OPTIONS
const PROP_SELECTION_TYPE
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...