static function displayTabContentForItem(CommonGLPI $item, $tabnum = 1, $withtemplate = 0) { global $CFG_GLPI; if ($item->getType() == 'PluginResourcesResource') { $ID = $item->getField('id'); self::showReports($ID, $withtemplate); if ($item->can($ID, 'w') && !self::checkIfReportsExist($ID)) { $self = new self(); $self->showForm("", array('plugin_resources_resources_id' => $ID, 'target' => $CFG_GLPI['root_doc'] . "/plugins/resources/front/reportconfig.form.php")); } if ($item->can($ID, 'w') && self::checkIfReportsExist($ID) && !$withtemplate) { PluginResourcesResource::showReportForm(array('id' => $ID, 'target' => $CFG_GLPI['root_doc'] . "/plugins/resources/front/resource.form.php")); } } return true; }