From a935b5466f2ab82cc96c7937007e71fa92bcf9fe Mon Sep 17 00:00:00 2001 From: RomainLvr Date: Mon, 23 Feb 2026 11:28:53 +0100 Subject: [PATCH 1/2] Fix - Add explicit itemtype to search option for GLPI custom dropdown fields --- hook.php | 2 +- inc/container.class.php | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/hook.php b/hook.php index 3ccd34ea..26ca1caf 100644 --- a/hook.php +++ b/hook.php @@ -211,7 +211,7 @@ function plugin_fields_MassiveActionsFieldsDisplay($options = []) $itemtypes = PluginFieldsContainer::getEntries('all'); if (in_array($options['itemtype'], $itemtypes)) { - if ($options['options']['is_multiple']) { + if (isset($options['options']['is_multiple']) && $options['options']['is_multiple']) { Dropdown::showFromArray( 'multiple_dropdown_action', [ diff --git a/inc/container.class.php b/inc/container.class.php index 12f685e9..f9599658 100644 --- a/inc/container.class.php +++ b/inc/container.class.php @@ -2221,6 +2221,7 @@ public static function getAddSearchOptions($itemtype, $containers_id = false) $opt[$i]['field'] = is_a($dropdown_matches['class'], CommonTreeDropdown::class, true) ? 'completename' : 'name'; + $opt[$i]['itemtype'] = $dropdown_matches['class']; $opt[$i]['right'] = 'all'; $opt[$i]['datatype'] = 'dropdown'; From 03bd3dee6ba2a56e76bd10424bc4d0b1f47a8151 Mon Sep 17 00:00:00 2001 From: RomainLvr Date: Mon, 23 Feb 2026 11:35:21 +0100 Subject: [PATCH 2/2] Update CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d85fa3d7..d555c56b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). ### Fixed - Fix SQL errors with custom dropdown fields +- Fix wrong values displayed in massive actions when a form contains multiple custom dropdowns ## [1.23.3] - 2026-02-12