mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-30 01:05:39 +02:00
fixed error metaconsole connection macros
This commit is contained in:
parent
88d8d12ccc
commit
e244d766a4
@ -135,7 +135,25 @@ function reporting_make_reporting_data($report = null, $id_report,
|
|||||||
$items_label['type'] = $content['type'];
|
$items_label['type'] = $content['type'];
|
||||||
$items_label['id_agent'] = $content['id_agent'];
|
$items_label['id_agent'] = $content['id_agent'];
|
||||||
$items_label['id_agent_module'] = $content['id_agent_module'];
|
$items_label['id_agent_module'] = $content['id_agent_module'];
|
||||||
|
$metaconsole_on = is_metaconsole();
|
||||||
|
$server_name = $content['server_name'];
|
||||||
|
|
||||||
|
//Metaconsole connection
|
||||||
|
if ($metaconsole_on && $server_name != '') {
|
||||||
|
$connection = metaconsole_get_connection($server_name);
|
||||||
|
if (!metaconsole_load_external_db($connection)) {
|
||||||
|
//ui_print_error_message ("Error connecting to ".$server_name);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$content['name'] = reporting_label_macro($items_label, $content['style']['name_label']);
|
$content['name'] = reporting_label_macro($items_label, $content['style']['name_label']);
|
||||||
|
|
||||||
|
if ($metaconsole_on) {
|
||||||
|
//Restore db connection
|
||||||
|
metaconsole_restore_db();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
switch (reporting_get_type($content)) {
|
switch (reporting_get_type($content)) {
|
||||||
case 'simple_graph':
|
case 'simple_graph':
|
||||||
|
Loading…
x
Reference in New Issue
Block a user