Skip to content

Commit

Permalink
fix(dropdownfield): compatibility with Document itemtype
Browse files Browse the repository at this point in the history
Signed-off-by: Thierry Bugier <[email protected]>
  • Loading branch information
btry committed Oct 26, 2020
1 parent 7d1a6af commit bc968b3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion inc/field/dropdownfield.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ public function buildParams($rand = null) {
'value' => $this->value,
'display' => false,
'comments' => false,
'entity' => $_SESSION['glpiactive_entity'], // TODO: replace by Session::getActiveEntity when dropping GLPI 9.4
'entity' => $_SESSION['glpiactiveentities'],
'displaywith' => ['id'],
];

Expand All @@ -220,6 +220,7 @@ public function buildParams($rand = null) {
break;

case Entity::class:
case Document::class:
unset($dparams['entity']);

case User::class:
Expand Down

0 comments on commit bc968b3

Please sign in to comment.