Skip to content

Commit 204c9b0

Browse files
authored
Fix(core): Hide fields 'tab' from template as it's content is not display (#930)
1 parent 4143330 commit 204c9b0

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

inc/container.class.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1138,6 +1138,11 @@ public static function getUsedItemtypes($type = 'all', $must_be_active = false)
11381138

11391139
public function getTabNameForItem(CommonGLPI $item, $withtemplate = 0)
11401140
{
1141+
if ($withtemplate) {
1142+
//Do not display tab from template or from item created from template
1143+
return '';
1144+
}
1145+
11411146
$itemtypes = self::getEntries('tab', true);
11421147
if (isset($itemtypes[$item->getType()]) && $item instanceof CommonDBTM) {
11431148
$tabs_entries = [];

0 commit comments

Comments
 (0)