public static function displayTabContentForItem(CommonGLPI $item, $tabnum = 1, $withtemplate = 0) { if ($item->getType() == 'Budget') { self::showForBudget($item->getField('id')); } elseif ($item->getType() == __CLASS__) { switch ($tabnum) { case 1: $item->showValidationForm($item->getID()); break; case 2: $item->showGenerationForm($item->getID()); break; } } return true; }