2014-07-23 Miguel de Dios <miguel.dedios@artica.es>
* include/functions_servers.php, include/functions_reporting.php: tiny fixes for the improve the support of postgreSQL databases. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@10351 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
1dc69b6e21
commit
5f1f44fb9a
|
@ -1,3 +1,8 @@
|
|||
2014-07-23 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* include/functions_servers.php, include/functions_reporting.php:
|
||||
tiny fixes for the improve the support of postgreSQL databases.
|
||||
|
||||
2014-07-23 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* operation/agentes/estado_generalagente.php: fixed the show the
|
||||
|
|
|
@ -907,6 +907,8 @@ function reporting_get_agentmodule_sla_array ($id_agent_module, $period = 0, $mi
|
|||
}
|
||||
|
||||
function reporting_get_stats_servers($tiny = true) {
|
||||
global $config;
|
||||
|
||||
$server_performance = servers_get_performance();
|
||||
|
||||
// Alerts table
|
||||
|
@ -1020,7 +1022,22 @@ function reporting_get_stats_servers($tiny = true) {
|
|||
$table_srv->rowclass[] = '';
|
||||
$table_srv->data[] = $tdata;
|
||||
|
||||
$system_events = db_get_value_sql('SELECT SQL_NO_CACHE COUNT(id_evento) FROM tevento');
|
||||
|
||||
switch ($config["dbtype"]) {
|
||||
case "mysql":
|
||||
$system_events = db_get_value_sql(
|
||||
'SELECT SQL_NO_CACHE COUNT(id_evento)
|
||||
FROM tevento');
|
||||
break;
|
||||
case "postgresql":
|
||||
case "oracle":
|
||||
$system_events = db_get_value_sql(
|
||||
'SELECT COUNT(id_evento)
|
||||
FROM tevento');
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
|
||||
$tdata = array();
|
||||
$tdata[0] = html_print_image('images/lightning_go.png', true, array('title' => __('Total events'), 'width' => '25px'));
|
||||
|
|
|
@ -195,6 +195,8 @@ function servers_get_performance () {
|
|||
$interval_avgs_agents = array();
|
||||
}
|
||||
|
||||
$interval_avgs = array();
|
||||
|
||||
// Merge with the previous calculated array
|
||||
foreach($interval_avgs_agents as $iaagents) {
|
||||
if(!isset($interval_avgs[$iaagents['id_modulo']]['modules'])) {
|
||||
|
|
Loading…
Reference in New Issue