Skip to content

Commit 2050c61

Browse files
committed
fix(abstacttarget): plugin fields dropdowns not saved on ITIL object
1 parent a2761ce commit 2050c61

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

inc/abstracttarget.class.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,10 @@ protected function appendFieldsData(PluginFormcreatorFormanswer $formanswer, &$i
241241
$field_name = $decodedValues['dropdown_fields_field'] ?? '';
242242
$blocks_field = $decodedValues['blocks_field'] ?? '';
243243

244-
if (strpos($field_name, 'dropdown') !== false) {
244+
$field = new PluginFieldsField();
245+
$field->getFromDbByCrit(['name' => $field_name]);
246+
247+
if ($field->fields['type'] == 'dropdown') {
245248
$dropdownInputName = "plugin_fields_" . $field_name . "dropdowns_id" ?? '';
246249
$input[$dropdownInputName] = $line['answer'];
247250
} else {

0 commit comments

Comments
 (0)