Skip to content

Commit 8d01aa6

Browse files
committed
feat(entityconfig): add icon to tab
1 parent acaa69c commit 8d01aa6

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

inc/entityconfig.class.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ public function getTabNameForItem(CommonGLPI $item, $withtemplate = 0) {
9090
$tabNames = [];
9191
if (!$withtemplate) {
9292
if ($item->getType() == 'Entity') {
93-
$tabNames[1] = _n('Form', 'Forms', 2, 'formcreator');
93+
$tabNames[1] = self::createTabEntry(_n('Form', 'Forms', Session::getPluralNumber(), 'formcreator'), 0, PluginFormcreatorForm::getType(), self::getIcon());
9494
}
9595
}
9696
return $tabNames;
@@ -199,6 +199,10 @@ public static function getEnumLeftMenuVisibility() : array {
199199
];
200200
}
201201

202+
public static function getIcon() {
203+
return 'fas fa-edit';
204+
}
205+
202206
public static function displayTabContentForItem(CommonGLPI $item, $tabnum = 1, $withtemplate = 0) {
203207
if ($item->getType() == 'Entity') {
204208
$config = new self();

0 commit comments

Comments
 (0)