Added feature. The report items SLA, Availaibily and General do not show the not init modules. TICKET: #2510

This commit is contained in:
mdtrooper 2015-07-21 13:10:44 +02:00
parent a8162a1876
commit a4b5f8607f
2 changed files with 15 additions and 4 deletions

View File

@ -626,7 +626,8 @@ function reporting_SLA($report, $content, $type = 'dinamic',
}
}
if (modules_is_disable_agent($sla['id_agent_module'])) {
if (modules_is_disable_agent($sla['id_agent_module'])
|| modules_is_not_init($item['id_agent_module'])) {
if ($metaconsole_on) {
//Restore db connection
metaconsole_restore_db();
@ -3673,7 +3674,10 @@ function reporting_availability($report, $content) {
}
}
if (modules_is_disable_agent($item['id_agent_module'])) {
if (modules_is_disable_agent($item['id_agent_module'])
|| modules_is_not_init($item['id_agent_module'])) {
//Restore dbconnection
if (($config ['metaconsole'] == 1) && $server_name != '' && defined('METACONSOLE')) {
metaconsole_restore_db();
@ -3905,7 +3909,14 @@ function reporting_general($report, $content) {
}
}
if (modules_is_disable_agent($row['id_agent_module'])) {
if (modules_is_disable_agent($row['id_agent_module']) ||
modules_is_not_init($item['id_agent_module'])) {
if (is_metaconsole()) {
//Restore db connection
metaconsole_restore_db();
}
continue;
}

View File

@ -132,7 +132,7 @@ if (!defined('METACONSOLE')) {
}
}
else {
if ($ag_group != "0" && check_acl ($config["id_user"], $id_ag_group, "AR")) {
$sql_conditions_group = sprintf (" AND tagente.id_grupo IN (%s) ", $ag_group);
}