Skip to content

Commit da0aa81

Browse files
committed
fix(glpiselectfield): restrict to items associatable to tickets
> > restriction on per item basis, like software Signed-off-by: Thierry Bugier <tbugier@teclib.com>
1 parent 1c6b647 commit da0aa81

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

inc/fields/dropdownfield.class.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,13 @@ public function getRenderedHtml($canEdit = true) {
242242
];
243243
$groups = implode("', '", $groups);
244244
}
245-
}
245+
// Check if helpdesk availability is fine tunable on a per item basis
246+
if ($DB->fieldExists($itemtype::getTable(), 'is_helpdesk_visible')) {
247+
$dparams_cond_crit[] = [
248+
'is_helpdesk_visible' => '1',
249+
];
250+
}
251+
}
246252
}
247253

248254
// Set specific root if defined (CommonTreeDropdown)

0 commit comments

Comments
 (0)