From 36c3f1fef6f5c5ec1f5d71d88d51f367382cfe4e Mon Sep 17 00:00:00 2001 From: enriquecd Date: Tue, 14 Nov 2017 13:51:33 +0100 Subject: [PATCH] Change group items url links in metaconsole - #1253 --- .../include/functions_visual_map.php | 34 +++++++++++-------- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/pandora_console/include/functions_visual_map.php b/pandora_console/include/functions_visual_map.php index 4fc59cd684..aa849eaeed 100755 --- a/pandora_console/include/functions_visual_map.php +++ b/pandora_console/include/functions_visual_map.php @@ -520,24 +520,28 @@ function visual_map_print_item($mode = "read", $layoutData, break; case GROUP_ITEM: - $is_a_link_to_other_visualconsole = false; - if ($layoutData['id_layout_linked'] != 0) { - $is_a_link_to_other_visualconsole = true; - } - - if ($is_a_link_to_other_visualconsole) { - if (empty($layout_data['id_metaconsole'])) { - $url = $config['homeurl'] . "index.php?sec=reporting&sec2=operation/visual_console/render_view&pure=" . $config["pure"] . "&id=" . $layoutData["id_layout_linked"]; + $is_a_link_to_other_visualconsole = false; + if ($layoutData['id_layout_linked'] != 0) { + $is_a_link_to_other_visualconsole = true; + } + if ($is_a_link_to_other_visualconsole) { + if (METACONSOLE == 1) { + $url = $config['homeurl'] . "index.php?sec=screen&sec2=screens/screens&action=visualmap&pure=0&id_visualmap=".$layoutData["id_layout_linked"]."&refr=300"; + } + else { + $url = $config['homeurl'] . "index.php?sec=reporting&sec2=operation/visual_console/render_view&pure=" . $config["pure"] . "&id=" . $layoutData["id_layout_linked"]; + } } else { - $url = "index.php?sec=screen&sec2=screens/screens&action=visualmap&pure=1&id_visualmap=" . $layoutData["id_layout_linked"] . "&refr=0"; + if (METACONSOLE == 1) { + $url = $config['homeurl'] . + 'index.php?sec=estado&sec2=operation/agentes/status_monitor&refr=0&ag_group='.$layoutData['id_group'].'&ag_freestring=&module_option=1&ag_modulename=&moduletype=&datatype=&status=-1&sort_field=&sort=none&pure='; + } + else { + $url = $config['homeurl'] . + 'index.php?sec=estado&sec2=operation/agentes/estado_agente&group_id='.$layoutData['id_group']; + } } - } - else { - $url = $config['homeurl'] . - 'index.php?sec=estado&sec2=operation/agentes/estado_agente&group_id=' . - $layoutData['id_group']; - } break; case LABEL: if ($layoutData['id_layout_linked'] != 0) {