3 require_once
"Services/ADT/classes/Bridges/class.ilADTSearchBridgeMulti.php";
17 $this->search_mode = (int) $a_mode;
22 return self::ENUM_SEARCH_COLUMN;
34 if ($a_adt_def->
getType() ==
"Enum") {
35 $this->multi_source =
false;
37 $def->setNumeric($a_adt_def->isNumeric());
38 $def->setOptions($a_adt_def->getOptions());
41 $this->multi_source =
true;
49 if ($value !== null) {
50 $this->
getADT()->setSelections($value);
63 $def = $this->
getADT()->getCopyOfDefinition();
65 $options = $def->getOptions();
69 $cbox->setValue($this->
getADT()->getSelections());
71 foreach ($options as $value => $caption) {
73 $cbox->addOption($option);
86 $item->setValue($post);
87 } elseif (array_key_exists($this->
getElementId(), $this->table_filter_fields)) {
88 $this->table_filter_fields[$this->
getElementId()]->setValue($post);
92 if (is_array($post)) {
93 $this->
getADT()->setSelections($post);
96 $this->
getADT()->setSelections();
107 $ilDB = $DIC->database();
112 $this->
getADT()->getSelections(),
123 $current = $this->
getADT()->getSelections();
124 if (is_array($current) &&
127 if ($this->search_mode == self::SEARCH_MODE_ANY) {
128 foreach ((array) $a_adt->getSelections() as $value) {
129 if (in_array($value, $current)) {
135 return !(bool)
sizeof(array_diff($current, (array) $a_adt->getSelections()));
147 return serialize($this->
getADT()->getSelections());
153 $a_value = unserialize($a_value);
154 if (is_array($a_value)) {
155 $this->
getADT()->setSelections($a_value);
convertADTDefinitionToMulti(ilADTDefinition $a_adt_def)
This class represents an option in a checkbox group.
static getInstance()
Get singleton.
extractPostValues(array $a_post=null)
Extract data from (post) values.
shouldBeImportedFromPost($a_post)
Check if incoming values should be imported at all.
importFromPost(array $a_post=null)
readFilter()
Load value(s) from filter store (in session)
getSQLCondition($a_element_id)
isValidADTDefinition(ilADTDefinition $a_adt_def)
writeFilter($a_value=null)
Write value(s) to filter store (in session)
isInCondition(ilADT $a_adt)
getType()
Get type (from class/instance)
ADT definition base class.
getElementId()
Get element id.
setSerializedValue($a_value)
addToParentElement(ilFormPropertyGUI $a_field)
Add form field to parent element.