isActivated('auf')) { // check if plugin is active if (Session::getLoginUserID()) { $PLUGIN_HOOKS['add_css']['auf'] = "auf.css"; } if (isset($_SESSION["glpiname"])) { $report_list = array(); if (Session::haveRight("computer", "r")) { $report_list["report.operatingsystems.php"] = "Systèmes d'exploitation par implantation"; $report_list["report.computers.php"] = "Ordinateurs par implantation"; // $report_list["report.wip.php"] = 'WIP (rapport en cours de développement)'; } $PLUGIN_HOOKS['reports']['auf'] = $report_list; } } } // Get the name and the version of the plugin - Needed function plugin_version_auf() { return array( 'name' => 'AUF', 'version' => '0.2.0', 'author' => 'Jean Christophe André', 'license' => 'GPLv2+', 'homepage' => 'http://git.auf.org/?p=glpi', 'minGlpiVersion' => '0.84');// For compatibility / no install in version < 0.80 } // Optional : check prerequisites before install : may print errors or add to message after redirect function plugin_auf_check_prerequisites() { if (version_compare(GLPI_VERSION,'0.84','lt') || version_compare(GLPI_VERSION,'0.85','ge')) { _e('This plugin requires GLPI >= 0.84', 'auf'); return FALSE; } return TRUE; } // Uninstall process for plugin : need to return true if succeeded : may display messages or add to message after redirect function plugin_auf_check_config() { return TRUE; } function plugin_auf_haveRight($module,$right) { return TRUE; } ?>