diff --git a/pandora_console/godmode/agentes/module_manager.php b/pandora_console/godmode/agentes/module_manager.php index 1fbf08bf80..b22bc0f626 100644 --- a/pandora_console/godmode/agentes/module_manager.php +++ b/pandora_console/godmode/agentes/module_manager.php @@ -45,10 +45,10 @@ echo ""; echo __('Search') . ' ' . html_print_input_text ('search_string', $search_string, '', 15, 255, true); echo ""; -echo ""; +echo ""; html_print_submit_button (__('Filter'), 'filter', false, 'class="sub search"'); echo ""; -echo ""; +echo ""; echo ''; // Check if there is at least one server of each type available to assign that // kind of modules. If not, do not show server type in combo @@ -119,7 +119,7 @@ if (($policy_page) || (isset($agent))) { // Create module/type combo echo '
'; if (!$policy_page) { - echo ''; + echo ''; echo __('Show in hierachy mode'); if ($checked == "true") { $checked = true; @@ -130,12 +130,12 @@ if (($policy_page) || (isset($agent))) { html_print_checkbox ('status_hierachy_mode', "", $checked, false, false, "onChange=change_mod_filter();"); echo ''; } - echo ''; + echo ''; echo __("Type"); html_print_select ($modules, 'moduletype', '', '', '', '', false, false, false, '', false, 'max-width:300px;' ); html_print_input_hidden ('edit_module', 1); echo ''; - echo ''; + echo ''; echo ''; echo ''; echo ''; diff --git a/pandora_console/godmode/agentes/module_manager_editor_common.php b/pandora_console/godmode/agentes/module_manager_editor_common.php index f66aa17296..9b9b96ffaf 100644 --- a/pandora_console/godmode/agentes/module_manager_editor_common.php +++ b/pandora_console/godmode/agentes/module_manager_editor_common.php @@ -291,7 +291,7 @@ if (modules_is_string_type($id_module_type) || $edit) { $table_simple->data[4][1] .= '
'.__('Inverse interval').''; $table_simple->data[4][1] .= html_print_checkbox ("warning_inverse", 1, $warning_inverse, true, $disabledBecauseInPolicy); if (!modules_is_string_type($id_module_type) || $edit) { - $table_simple->data[4][2] = ' '; + $table_simple->data[4][2] = ''; $table_simple->colspan[4][2] = 2; $table_simple->rowspan[4][2] = 3; } @@ -1323,8 +1323,8 @@ function paint_graph_status(min_w, max_w, min_c, max_c, inverse_w, inverse_c, er .attr("id", "legend_normal") .attr("x", 72) .attr("y", -30) - .attr("width", 10) - .attr("height", 10) + .attr("width", '10px') + .attr("height", '10px') .style("fill", "#82B92E"); //legend Warning text @@ -1343,8 +1343,8 @@ function paint_graph_status(min_w, max_w, min_c, max_c, inverse_w, inverse_c, er .attr("id", "legend_warning") .attr("x", 168) .attr("y", -30) - .attr("width", 10) - .attr("height", 10) + .attr("width", '10px') + .attr("height", '10px') .style("fill", "#ffd731"); //legend Critical text @@ -1363,8 +1363,8 @@ function paint_graph_status(min_w, max_w, min_c, max_c, inverse_w, inverse_c, er .attr("id", "legend_critical") .attr("x", 258) .attr("y", -30) - .attr("width", 10) - .attr("height", 10) + .attr("width", '10px') + .attr("height", '10px') .style("fill", "#fc4444"); //styles for number and axes @@ -1382,8 +1382,8 @@ function paint_graph_status(min_w, max_w, min_c, max_c, inverse_w, inverse_c, er .attr("id", "warning_rect") .attr("x", 3) .attr("y", 0) - .attr("width", 300) - .attr("height", 200) + .attr("width", '300px') + .attr("height", '200px') .style("fill", "#82B92E"); //controls the inverse warning diff --git a/pandora_console/godmode/modules/manage_network_components_form_common.php b/pandora_console/godmode/modules/manage_network_components_form_common.php index 83b21b225b..b9cc96a468 100644 --- a/pandora_console/godmode/modules/manage_network_components_form_common.php +++ b/pandora_console/godmode/modules/manage_network_components_form_common.php @@ -473,8 +473,8 @@ $next_row++; .attr("id", "legend_normal") .attr("x", 72) .attr("y", -30) - .attr("width", 10) - .attr("height", 10) + .attr("width", '10px') + .attr("height", '10px') .style("fill", "#82B92E"); //legend Warning text diff --git a/pandora_console/godmode/reporting/visual_console_builder.editor.js b/pandora_console/godmode/reporting/visual_console_builder.editor.js index e8c7396e6a..f501978770 100755 --- a/pandora_console/godmode/reporting/visual_console_builder.editor.js +++ b/pandora_console/godmode/reporting/visual_console_builder.editor.js @@ -388,6 +388,7 @@ function update_button_palette_callback() { else { setPercentileBar(idItem, values); } + break; case 'module_graph': if($('#dir_items').html() == 'horizontal'){ @@ -1292,7 +1293,14 @@ function loadFieldsFromDB(item) { } if (key == 'value_show') { - $("select[name=value_show]").val(val); + if (val == 'percent') { + $("input[name=value_show][value=percent]") + .attr("checked", "checked"); + } + else { + $("input[name=value_show][value=value]") + .attr("checked", "checked"); + } } if (key == 'id_group') { diff --git a/pandora_console/godmode/reporting/visual_console_builder.editor.php b/pandora_console/godmode/reporting/visual_console_builder.editor.php index 28307766fd..88ea386ee6 100755 --- a/pandora_console/godmode/reporting/visual_console_builder.editor.php +++ b/pandora_console/godmode/reporting/visual_console_builder.editor.php @@ -196,11 +196,18 @@ ui_require_javascript_file ('encode_decode_base64'); "10pt=.visual_font_size_10pt, " + "12pt=.visual_font_size_12pt, " + "14pt=.visual_font_size_14pt, " + + "18pt=.visual_font_size_18pt, " + "24pt=.visual_font_size_24pt, " + + "28pt=.visual_font_size_28pt, " + "36pt=.visual_font_size_36pt, " + + "48pt=.visual_font_size_48pt, " + + "60pt=.visual_font_size_60pt, " + "72pt=.visual_font_size_72pt, " + + "84pt=.visual_font_size_84pt, " + "96pt=.visual_font_size_96pt, " + + "116pt=.visual_font_size_116pt, " + "128pt=.visual_font_size_128pt, " + + "140pt=.visual_font_size_140pt, " + "154pt=.visual_font_size_154pt, " + "196pt=.visual_font_size_196pt", theme_advanced_toolbar_location : "top", diff --git a/pandora_console/godmode/reporting/visual_console_builder.elements.php b/pandora_console/godmode/reporting/visual_console_builder.elements.php index 15134a9c1d..c7e63358fa 100755 --- a/pandora_console/godmode/reporting/visual_console_builder.elements.php +++ b/pandora_console/godmode/reporting/visual_console_builder.elements.php @@ -602,11 +602,18 @@ ui_require_javascript_file('tiny_mce', 'include/javascript/tiny_mce/'); "10pt=.visual_font_size_10pt, " + "12pt=.visual_font_size_12pt, " + "14pt=.visual_font_size_14pt, " + + "18pt=.visual_font_size_18pt, " + "24pt=.visual_font_size_24pt, " + + "28pt=.visual_font_size_28pt, " + "36pt=.visual_font_size_36pt, " + + "48pt=.visual_font_size_48pt, " + + "60pt=.visual_font_size_60pt, " + "72pt=.visual_font_size_72pt, " + + "84pt=.visual_font_size_84pt, " + "96pt=.visual_font_size_96pt, " + + "116pt=.visual_font_size_116pt, " + "128pt=.visual_font_size_128pt, " + + "140pt=.visual_font_size_140pt, " + "154pt=.visual_font_size_154pt, " + "196pt=.visual_font_size_196pt", theme_advanced_toolbar_location : "top", diff --git a/pandora_console/godmode/reporting/visual_console_builder.wizard.php b/pandora_console/godmode/reporting/visual_console_builder.wizard.php index 67273ed795..42d6d608cd 100644 --- a/pandora_console/godmode/reporting/visual_console_builder.wizard.php +++ b/pandora_console/godmode/reporting/visual_console_builder.wizard.php @@ -144,7 +144,7 @@ $table->data["staticgraph_modulegraph"][1] .= '   ' . 'leaguegothic' => 'League Gothic' ); - $fonts = array('4pt' => '4pt','6pt' => '6pt','8pt' => '8pt','10pt' => '10pt','12pt' => '12pt','14pt' => '14pt','24pt' => '24pt','36pt' => '36pt','72pt' => '72pt','96pt' => '96pt','128pt' => '128pt','154pt' => '154pt','196pt' => '196pt'); + $fonts = array('4pt' => '4pt','6pt' => '6pt','8pt' => '8pt','10pt' => '10pt','12pt' => '12pt','14pt' => '14pt','18pt' => '18pt','24pt' => '24pt','28pt' => '28pt','36pt' => '36pt','48pt' => '48pt','60pt' => '60pt','72pt' => '72pt','84pt' => '84pt','96pt' => '96pt','116pt' => '116pt','128pt' => '128pt','140pt' => '140pt','154pt' => '154pt','196pt' => '196pt'); /* $fontf = array('andale mono,times' => 'Andale Mono', diff --git a/pandora_console/godmode/setup/setup_visuals.php b/pandora_console/godmode/setup/setup_visuals.php index 6a82812f1a..145904d85d 100755 --- a/pandora_console/godmode/setup/setup_visuals.php +++ b/pandora_console/godmode/setup/setup_visuals.php @@ -934,6 +934,23 @@ tinyMCE.init({ }); $(document).ready (function () { + + var comfort = 0; + + if(comfort == 0){ + $(':input,:radio,:checkbox,:file').change(function(){ + $('#submit-update_button').css({'position':'fixed','right':'80px','bottom':'55px'}); + var comfort = 1; + }); + + $("*").keydown(function(){ + $('#submit-update_button').css({'position':'fixed','right':'80px','bottom':'55px'}); + var comfort = 1; + }); + + $('#form_setup').after('
'); + } + $("#form_setup #text-graph_color1").attachColorPicker(); $("#form_setup #text-graph_color2").attachColorPicker(); $("#form_setup #text-graph_color3").attachColorPicker(); diff --git a/pandora_console/godmode/update_manager/update_manager.offline.php b/pandora_console/godmode/update_manager/update_manager.offline.php index 2079678fa8..afad03cc2c 100644 --- a/pandora_console/godmode/update_manager/update_manager.offline.php +++ b/pandora_console/godmode/update_manager/update_manager.offline.php @@ -58,7 +58,14 @@ $baseurl = ui_get_full_url(false, false, false, false); var text1_mr_file = "\n"; var text2_mr_file = "\n"; var text3_mr_file = "\n"; - var text4_mr_file = "\n"; + var text4_mr_file = "
'.__('About minor release update').''; + } + else{ + echo __(' to this process').'

'.__('About minor release update').''; + } + ?>"; var text1_package_file = "\n"; var text2_package_file = "\n"; var applying_mr = "\n"; diff --git a/pandora_console/images/console/signes/barras-no.png b/pandora_console/images/console/signes/barras-no.png new file mode 100644 index 0000000000..c4545405e0 Binary files /dev/null and b/pandora_console/images/console/signes/barras-no.png differ diff --git a/pandora_console/images/console/signes/barras.png b/pandora_console/images/console/signes/barras.png new file mode 100644 index 0000000000..be81fb2212 Binary files /dev/null and b/pandora_console/images/console/signes/barras.png differ diff --git a/pandora_console/images/console/signes/donut-graph.png b/pandora_console/images/console/signes/donut-graph.png new file mode 100644 index 0000000000..57a2d3eb2b Binary files /dev/null and b/pandora_console/images/console/signes/donut-graph.png differ diff --git a/pandora_console/images/console/signes/wrong_donut_graph.png b/pandora_console/images/console/signes/wrong_donut_graph.png new file mode 100644 index 0000000000..8005a9ac46 Binary files /dev/null and b/pandora_console/images/console/signes/wrong_donut_graph.png differ diff --git a/pandora_console/images/icono-barras-arriba.disabled.png b/pandora_console/images/icono-barras-arriba.disabled.png new file mode 100644 index 0000000000..94fb50dc5f Binary files /dev/null and b/pandora_console/images/icono-barras-arriba.disabled.png differ diff --git a/pandora_console/images/icono-barras-arriba.png b/pandora_console/images/icono-barras-arriba.png new file mode 100644 index 0000000000..4029c48c87 Binary files /dev/null and b/pandora_console/images/icono-barras-arriba.png differ diff --git a/pandora_console/images/icono-quesito.disabled.png b/pandora_console/images/icono-quesito.disabled.png new file mode 100644 index 0000000000..8202e2040b Binary files /dev/null and b/pandora_console/images/icono-quesito.disabled.png differ diff --git a/pandora_console/images/icono-quesito.png b/pandora_console/images/icono-quesito.png new file mode 100644 index 0000000000..f1a0ed73ff Binary files /dev/null and b/pandora_console/images/icono-quesito.png differ diff --git a/pandora_console/include/ajax/graph.ajax.php b/pandora_console/include/ajax/graph.ajax.php index 1b537f8a48..ac7decf965 100644 --- a/pandora_console/include/ajax/graph.ajax.php +++ b/pandora_console/include/ajax/graph.ajax.php @@ -64,7 +64,7 @@ if ($print_custom_graph) { $ttl = (int) get_parameter('ttl', 1); $dashboard = (bool) get_parameter('dashboard'); $vconsole = (bool) get_parameter('vconsole'); - + echo custom_graphs_print($id_graph, $height, $width, $period, $stacked, true, $date, $only_image, $background_color, $modules_param, $homeurl, $name_list, $unit_list, $show_last, $show_max, @@ -102,13 +102,14 @@ if ($print_sparse_graph) { $percentil = get_parameter('percentil', null); $dashboard = (bool) get_parameter('dashboard'); $vconsole = (bool) get_parameter('vconsole'); + $type_g = get_parameter('type_g', $config['type_module_charts']); echo grafico_modulo_sparse($agent_module_id, $period, $show_events, $width, $height , $title, $unit_name, $show_alerts, $avg_only, $pure, $date, $unit, $baseline, $return_data, $show_title, $only_image, $homeurl, $ttl, $projection, $adapt_key, $compare, $show_unknown, $menu, $backgroundColor, $percentil, - $dashboard, $vconsole, $config['type_module_charts']); + $dashboard, $vconsole, $type_g); return; } diff --git a/pandora_console/include/ajax/visual_console_builder.ajax.php b/pandora_console/include/ajax/visual_console_builder.ajax.php index 0d63e57934..9ed90e3624 100755 --- a/pandora_console/include/ajax/visual_console_builder.ajax.php +++ b/pandora_console/include/ajax/visual_console_builder.ajax.php @@ -468,6 +468,8 @@ switch ($action) { case 'label': case 'icon': case 'auto_sla_graph': + case 'bars_graph': + case 'donut_graph': default: if ($type == 'label') { $values['type'] = LABEL; @@ -518,11 +520,11 @@ switch ($action) { $values['id_agent'] = $id_agent; } } - else if ($agent !== null) { - $id_agent = agents_get_agent_id($agent); + else if (!empty($id_agent)) { $values['id_agent'] = $id_agent; } - else { + else if ($agent !== null) { + $id_agent = agents_get_agent_id($agent); $values['id_agent'] = $id_agent; } if ($id_module !== null) { @@ -977,9 +979,6 @@ switch ($action) { $values['image'] = $image; $values['width'] = $width; $values['height'] = $height; - if(defined('METACONSOLE') && $values['id_agent'] == 0){ - $values['id_metaconsole'] = 1; - } break; case 'group_item': $values['type'] = GROUP_ITEM; @@ -998,18 +997,12 @@ switch ($action) { case 'label': $values['type'] = LABEL; $values['label'] = $label; - if(defined('METACONSOLE') && $values['id_agent'] == 0){ - $values['id_metaconsole'] = 1; - } break; case 'icon': $values['type'] = ICON; $values['image'] = $image; $values['width'] = $width; $values['height'] = $height; - if(defined('METACONSOLE') && $values['id_agent'] == 0){ - $values['id_metaconsole'] = 1; - } break; default: if (enterprise_installed()) { diff --git a/pandora_console/include/constants.php b/pandora_console/include/constants.php index 08c3fc55da..ba4efa5535 100644 --- a/pandora_console/include/constants.php +++ b/pandora_console/include/constants.php @@ -199,6 +199,8 @@ define('BOX_ITEM', 12); define('LINE_ITEM', 13); define('CIRCULAR_PROGRESS_BAR', 15); define('CIRCULAR_INTERIOR_PROGRESS_BAR', 16); +define('DONUT_GRAPH', 17); +define('BARS_GRAPH', 18); //Some styles define('MIN_WIDTH', 300); define('MIN_HEIGHT', 120); diff --git a/pandora_console/include/functions_graph.php b/pandora_console/include/functions_graph.php index 9d66670864..5d33c49a01 100644 --- a/pandora_console/include/functions_graph.php +++ b/pandora_console/include/functions_graph.php @@ -2119,7 +2119,7 @@ function graphic_combined_module ($module_list, $weight_list, $period, case CUSTOM_GRAPH_PIE: return ring_graph($flash_charts, $graph_values, $width, $height, $others_str, $homeurl, $water_mark, $config['fontpath'], - ($config['font_size']+1), $ttl, false, $color, false); + ($config['font_size']+1), $ttl, false, $color, false,$background_color); break; } } diff --git a/pandora_console/include/functions_update_manager.php b/pandora_console/include/functions_update_manager.php index 607b108e42..ba6508fa19 100755 --- a/pandora_console/include/functions_update_manager.php +++ b/pandora_console/include/functions_update_manager.php @@ -358,7 +358,14 @@ function update_manager_check_online_free_packages ($is_ajax=true) { var text1_mr_file = "\n"; var text2_mr_file = "\n"; var text3_mr_file = "\n"; - var text4_mr_file = "\n"; + var text4_mr_file = "
'.__('About minor release update').''; + } + else{ + echo __(' to this process').'

'.__('About minor release update').''; + } + ?>"; var text1_package_file = "\n"; var text2_package_file = "\n"; var applying_mr = "\n"; diff --git a/pandora_console/include/functions_visual_map.php b/pandora_console/include/functions_visual_map.php index c18f511098..d02c25dc9d 100755 --- a/pandora_console/include/functions_visual_map.php +++ b/pandora_console/include/functions_visual_map.php @@ -424,7 +424,7 @@ function visual_map_print_item($mode = "read", $layoutData, } } else if ($is_a_link_to_other_visualconsole) { - if (empty($layoutData['id_metaconsole'])) { + 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"]; } else { @@ -490,6 +490,29 @@ function visual_map_print_item($mode = "read", $layoutData, "&date_to=" . $date_to . "&time_to=" . $time_to . "&status=-1"; } break; + + case DONUT_GRAPH: + if (empty($layout_data['id_metaconsole'])) { + $url = $config['homeurl'] . "index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&id_agente=" . $layoutData['id_agent'] . + "&tab=module&edit_module=1&id_agent_module=" . $layoutData['id_agente_modulo']; + } + else { + $url = "index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&id_agente=" . $layoutData['id_agent'] . + "&tab=module&edit_module=1&id_agent_module=" . $layoutData['id_agente_modulo']; + } + break; + + case BARS_GRAPH: + if (empty($layout_data['id_metaconsole'])) { + $url = $config['homeurl'] . "index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&id_agente=" . $layoutData['id_agent'] . + "&tab=module&edit_module=1&id_agent_module=" . $layoutData['id_agente_modulo']; + } + else { + $url = "index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&id_agente=" . $layoutData['id_agent'] . + "&tab=module&edit_module=1&id_agent_module=" . $layoutData['id_agente_modulo']; + } + break; + case GROUP_ITEM: $is_a_link_to_other_visualconsole = false; if ($layoutData['id_layout_linked'] != 0) { @@ -513,20 +536,15 @@ function visual_map_print_item($mode = "read", $layoutData, case LABEL: if ($layoutData['id_layout_linked'] != 0) { // Link to a map - if ($layoutData['id_metaconsole'] == 0) { - $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=0&id_visualmap=" . $layoutData["id_layout_linked"] . "&refr=0"; - } + $url = $config['homeurl'] . + 'index.php?sec=reporting&sec2=operation/visual_console/render_view&pure='.$config["pure"].'&id='.$layoutData["id_layout_linked"]; } break; case ICON: $url_icon = ""; if ($layoutData['id_layout_linked'] != 0) { // Link to a map - if ($layoutData['id_metaconsole'] == 0) { + if (empty($layoutData['id_metaconsole'])) { $url = 'index.php?sec=reporting&sec2=operation/visual_console/render_view&pure='.$config["pure"].'&id='.$layoutData["id_layout_linked"]; } else { @@ -1088,10 +1106,10 @@ function visual_map_print_item($mode = "read", $layoutData, if ((get_parameter('action') == 'edit') || (get_parameter('operation') == 'edit_visualmap')) { if($width == 0 || $height == 0){ if ($layoutData['id_metaconsole'] != 0) { - $img = ''; + $img = ''; } else{ - $img = ''; + $img = ''; } } else{ @@ -1189,12 +1207,7 @@ function visual_map_print_item($mode = "read", $layoutData, if ($link) { echo ""; } - - //for clean link text from bbdd - if (get_parameter('action') == 'edit' || get_parameter('operation') == 'edit_visualmap') { - $text = preg_replace("/<\/*a.*?>/", '', $text); - } - + switch ($type) { case BOX_ITEM: if ($width == 0 || $width == 0) { @@ -1287,12 +1300,9 @@ function visual_map_print_item($mode = "read", $layoutData, $imgpos = 'float:left'; } - if ($layoutData['id_metaconsole'] != 0) { - $img = "../../" . $img; - } - $varsize = getimagesize($img); + if($layoutData['show_statistics'] == 1){ if (get_parameter('action') == 'edit') { @@ -1386,35 +1396,34 @@ function visual_map_print_item($mode = "read", $layoutData, else{ if ($width == 0 || $height == 0) { - if($varsize[0] > 150 || $varsize[1] > 150){ echo html_print_image($img, true, - array("class" => "image", - "id" => "image_" . $id, - "width" => "70px", - "height" => "70px", - "title" => $img_style_title, - "style" => $borderStyle.$imgpos), false, - false, false, $isExternalLink); + array("class" => "image", + "id" => "image_" . $id, + "width" => "70px", + "height" => "70px", + "title" => $img_style_title, + "style" => $borderStyle.$imgpos), false, + false, false, $isExternalLink); } else{ echo html_print_image($img, true, - array("class" => "image", - "id" => "image_" . $id, - "title" => $img_style_title, - "style" => $borderStyle.$imgpos), false, - false, false, $isExternalLink); + array("class" => "image", + "id" => "image_" . $id, + "title" => $img_style_title, + "style" => $borderStyle.$imgpos), false, + false, false, $isExternalLink); } } else{ - echo html_print_image($img, true, - array("class" => "image", - "id" => "image_" . $id, - "width" => $width, - "height" => $height, - "title" => $img_style_title, - "style" => $borderStyle.$imgpos), false, - false, false, $isExternalLink); + echo html_print_image($img, true, + array("class" => "image", + "id" => "image_" . $id, + "width" => $width, + "height" => $height, + "title" => $img_style_title, + "style" => $borderStyle.$imgpos), false, + false, false, $isExternalLink); } } @@ -2755,10 +2764,9 @@ function visual_map_print_visual_map ($id_layout, $show_links = true, $mapWidth = $layout["width"]; $mapHeight = $layout["height"]; $backgroundImage = ''; - if ($layout["background"] != 'None.png' ){ + if ($layout["background"] != 'None.png' ) $backgroundImage = $metaconsole_hack . 'images/console/background/' . $layout["background"]; - } } if (defined('METACONSOLE')) { @@ -2853,33 +2861,14 @@ function visual_map_print_visual_map ($id_layout, $show_links = true, * @return array A list of layouts the user can see. */ function visual_map_get_user_layouts ($id_user = 0, $only_names = false, $filter = false, $returnAllGroup = true) { - if (! is_array ($filter)){ + if (! is_array ($filter)) $filter = array (); - } else { - if(!empty($filter['name'])){ - $where .= "name LIKE '%".io_safe_output($filter['name'])."%'"; - unset($filter['name']); - } - } - - if ($returnAllGroup){ + + if ($returnAllGroup) $groups = users_get_groups ($id_user, 'VR'); - } else { - if(!empty($filter['group'])){ - $permissions_group = users_get_groups ($id_user, 'VR', false); - if(empty($permissions_group)){ - $permissions_group = users_get_groups ($id_user, 'VM', false); - } - $groups = array_intersect_key($filter['group'], $permissions_group); - unset($filter['group']); - } else { - $groups = users_get_groups ($id_user, 'VR', false); - if(empty($groups)){ - $groups = users_get_groups ($id_user, 'VM', false); - } - } - } - + else + $groups = users_get_groups ($id_user, 'VR', false); + if (!empty($groups)) { if (empty($where)) $where = ""; diff --git a/pandora_console/include/functions_visual_map_editor.php b/pandora_console/include/functions_visual_map_editor.php index 9c13cd2d60..63abd33ac2 100755 --- a/pandora_console/include/functions_visual_map_editor.php +++ b/pandora_console/include/functions_visual_map_editor.php @@ -220,7 +220,7 @@ function visual_map_editor_print_item_palette($visualConsole_id, $background) { $form_items['enable_link_row']['html'] = '' . __('Enable link') . ' ' . - html_print_checkbox('enable_link', '', 1, true) . ''; + html_print_checkbox('enable_link', '', !is_metaconsole(), true) . ''; $form_items['preview_row'] = array(); @@ -275,7 +275,7 @@ function visual_map_editor_print_item_palette($visualConsole_id, $background) { $form_items['agent_row'] = array(); $form_items['agent_row']['items'] = array('static_graph', 'percentile_bar', 'percentile_item', 'module_graph', - 'simple_value', 'datos', 'auto_sla_graph'); + 'simple_value', 'datos', 'auto_sla_graph', 'bars_graph', 'donut_graph'); $form_items['agent_row']['html'] = '' . __('Agent') . ''; $params = array(); @@ -308,7 +308,7 @@ function visual_map_editor_print_item_palette($visualConsole_id, $background) { $form_items['module_row'] = array(); $form_items['module_row']['items'] = array('static_graph', 'percentile_bar', 'percentile_item', 'module_graph', - 'simple_value', 'datos', 'auto_sla_graph'); + 'simple_value', 'datos', 'auto_sla_graph', 'donut_graph', 'bars_graph'); $form_items['module_row']['html'] = '' . __('Module') . ' ' . @@ -394,7 +394,7 @@ function visual_map_editor_print_item_palette($visualConsole_id, $background) { $form_items['percentile_bar_row_1'] = array(); - $form_items['percentile_bar_row_1']['items'] = array('percentile_bar', 'percentile_item', 'datos'); + $form_items['percentile_bar_row_1']['items'] = array('percentile_bar', 'percentile_item', 'datos', 'donut_graph', 'bars_graph'); $form_items['percentile_bar_row_1']['html'] = '' . __('Width') . ' ' . html_print_input_text('width_percentile', 0, '', 3, 5, true) . ''; @@ -573,11 +573,12 @@ function visual_map_editor_print_item_palette($visualConsole_id, $background) { ''; $form_items_advance['map_linked_row'] = array(); - $form_items_advance['map_linked_row']['items'] = array('static_graph', 'label', 'icon'); + $form_items_advance['map_linked_row']['items'] = array( + 'group_item', 'static_graph', 'percentile_bar', + 'percentile_item', 'module_graph', 'simple_value', + 'icon', 'label', 'datos'); $form_items_advance['map_linked_row']['html'] = ''. - __('Map linked') . ui_print_help_tip ( - __("If a parent visual console is selected here, an agent or module cannot be selected and will be removed if a previous selection was done."), true) . - '' . + __('Map linked') . '' . '' . html_print_select_from_sql ( 'SELECT id, name FROM tlayout @@ -692,6 +693,8 @@ function visual_map_editor_print_toolbox() { visual_map_print_button_editor('static_graph', __('Static Graph'), 'left', false, 'camera_min', true); visual_map_print_button_editor('percentile_item', __('Percentile Item'), 'left', false, 'percentile_item_min', true); visual_map_print_button_editor('module_graph', __('Module Graph'), 'left', false, 'graph_min', true); + visual_map_print_button_editor('donut_graph', __('Donut Graph'), 'left', false, 'donut_graph_min', true); + visual_map_print_button_editor('bars_graph', __('Bars Graph'), 'left', false, 'bars_graph_min', true); visual_map_print_button_editor('auto_sla_graph', __('Auto SLA Graph'), 'left', false, 'auto_sla_graph_min', true); visual_map_print_button_editor('simple_value', __('Simple Value'), 'left', false, 'binary_min', true); visual_map_print_button_editor('label', __('Label'), 'left', false, 'label_min', true); @@ -765,18 +768,4 @@ function visual_map_editor_print_hack_translate_strings() { echo ''; } -?> - - \ No newline at end of file +?> \ No newline at end of file diff --git a/pandora_console/include/graphs/fgraph.php b/pandora_console/include/graphs/fgraph.php index ed12555593..74a2ea251d 100644 --- a/pandora_console/include/graphs/fgraph.php +++ b/pandora_console/include/graphs/fgraph.php @@ -188,7 +188,7 @@ function vbar_graph($flash_chart, $chart_data, $width, $height, if ($flash_chart) { return flot_vcolumn_chart ($chart_data, $width, $height, $color, $legend, $long_index, $homeurl, $unit, $water_mark_url, - $homedir,$font,$font_size, $from_ux, $from_wux); + $homedir,$font,$font_size, $from_ux, $from_wux, $backgroundColor); } else { foreach ($chart_data as $key => $value) { @@ -652,7 +652,7 @@ function hbar_graph($flash_chart, $chart_data, $width, $height, if ($flash_chart) { return flot_hcolumn_chart( - $chart_data, $width, $height, $water_mark_url, $font, $font_size); + $chart_data, $width, $height, $water_mark_url, $font, $font_size, $backgroundColor); } else { @@ -784,7 +784,7 @@ function pie_graph($graph_type, $flash_chart, $chart_data, $width, function ring_graph($flash_chart, $chart_data, $width, $height, $others_str = "other", $homedir="", $water_mark = "", $font = '', $font_size = '', $ttl = 1, $legend_position = false, - $colors = '', $hide_labels = false) { + $colors = '', $hide_labels = false,$background_color = 'white') { if (empty($chart_data)) { return graph_nodata_image($width, $height, 'pie'); @@ -800,7 +800,7 @@ function ring_graph($flash_chart, $chart_data, $width, return flot_custom_pie_chart ($flash_chart, $chart_data, $width, $height, $colors, $module_name_list, $long_index, $no_data, false, '', $water_mark, $font, $font_size, - $unit, $ttl, $homeurl, $background_color, $legend_position); + $unit, $ttl, $homeurl, $background_color, $legend_position,$background_color); } else { $total_modules = $chart_data['total_modules']; diff --git a/pandora_console/include/graphs/flot/pandora.flot.js b/pandora_console/include/graphs/flot/pandora.flot.js index e036a9855e..10b98be29b 100644 --- a/pandora_console/include/graphs/flot/pandora.flot.js +++ b/pandora_console/include/graphs/flot/pandora.flot.js @@ -119,7 +119,8 @@ function pandoraFlotPie(graph_id, values, labels, nseries, width, font_size, wat function pandoraFlotPieCustom(graph_id, values, labels, width, font_size, font, water_mark, separator, legend_position, height, - colors,legend) { + colors,legend,background_color) { + font = font.split("/").pop().split(".").shift(); var labels = labels.split(separator); var legend = legend.split(separator); @@ -211,8 +212,24 @@ function pandoraFlotPieCustom(graph_id, values, labels, width, $('.legend>table').css('right',($('.legend>div').height()*-1)); } //$('.legend>table').css('border',"1px solid #E2E2E2"); - $('.legend>table').css('background-color',"transparent"); + if(background_color == 'transparent'){ + $('.legend>table').css('background-color',""); + $('.legend>div').css('background-color',""); + $('.legend>table').css('color',"#aaa"); + } + else if (background_color == 'white') { + $('.legend>table').css('background-color',"white"); + $('.legend>table').css('color',"black"); + } + else if (background_color == 'black') { + $('.legend>table').css('background-color',"black"); + $('.legend>table').css('color',"#aaa"); + } + + $('.legend').over(function(){ + return false; + }); var pielegends = $('#'+graph_id+' .pieLabelBackground'); pielegends.each(function () { @@ -309,7 +326,7 @@ function pandoraFlotPieCustom(graph_id, values, labels, width, } function pandoraFlotHBars(graph_id, values, labels, water_mark, - maxvalue, water_mark, separator, separator2, font, font_size) { + maxvalue, water_mark, separator, separator2, font, font_size, background_color) { var colors_data = ['#FC4444','#FFA631','#FAD403','#5BB6E5','#F2919D','#80BA27']; values = values.split(separator2); @@ -355,7 +372,7 @@ function pandoraFlotHBars(graph_id, values, labels, water_mark, grid: { hoverable: true, borderWidth: 1, - backgroundColor: { colors: ["#FFF", "#FFF"] } + backgroundColor: { colors: [background_color, background_color] } }, xaxis: { axisLabelUseCanvas: true, @@ -494,7 +511,7 @@ function showTooltip(x, y, color, contents) { }).appendTo("body").fadeIn(200); } -function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors, water_mark, maxvalue, water_mark, separator, separator2, font, font_size , from_ux, from_wux) { +function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors, water_mark, maxvalue, water_mark, separator, separator2, font, font_size , from_ux, from_wux, background_color) { values = values.split(separator2); legend = legend.split(separator); font = font.split("/").pop().split(".").shift(); @@ -585,7 +602,7 @@ function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors, grid: { hoverable: true, borderWidth: 1, - backgroundColor: { colors: ["#FFF", "#FFF"] } + backgroundColor: { colors: [background_color, background_color] } } }; @@ -608,16 +625,7 @@ function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors, $('#' + graph_id).VUseTooltip(); $('#' + graph_id).css("margin-left","auto"); $('#' + graph_id).css("margin-right","auto"); - //~ $('#' + graph_id).find('div.legend-tooltip').tooltip({ track: true }); - /* - $('#'+graph_id+' .xAxis .tickLabel') - .css('transform', 'rotate(-45deg)') - .css('max-width','100px') - .find('div') - .css('position', 'relative') - .css('top', '+10px') - .css('left', '-30px'); - */ + if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) $('#'+graph_id+' .xAxis .tickLabel') .find('div') @@ -638,7 +646,7 @@ function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors, } format.push([i, - '
' + '
' + label + '
']); } diff --git a/pandora_console/include/graphs/functions_flot.php b/pandora_console/include/graphs/functions_flot.php index 7e30d49215..58b193b0e7 100644 --- a/pandora_console/include/graphs/functions_flot.php +++ b/pandora_console/include/graphs/functions_flot.php @@ -666,7 +666,7 @@ function flot_custom_pie_chart ($flash_charts, $graph_values, $return .= "pandoraFlotPieCustom('$graph_id', '$values', '$labels', '$width', $font_size, '$fontpath', $water_mark, - '$separator', '$legend_position', '$height', '$colors','$legend')"; + '$separator', '$legend_position', '$height', '$colors','$legend','$background_color')"; $return .= ""; @@ -674,7 +674,7 @@ function flot_custom_pie_chart ($flash_charts, $graph_values, } // Returns a 3D column chart -function flot_hcolumn_chart ($graph_data, $width, $height, $water_mark, $font = '', $font_size = 7) { +function flot_hcolumn_chart ($graph_data, $width, $height, $water_mark, $font = '', $font_size = 7, $background_color = "white") { global $config; include_javascript_dependencies_flot_graph(); @@ -755,7 +755,7 @@ function flot_hcolumn_chart ($graph_data, $width, $height, $water_mark, $font = $return .= ""; @@ -763,7 +763,7 @@ function flot_hcolumn_chart ($graph_data, $width, $height, $water_mark, $font = } // Returns a 3D column chart -function flot_vcolumn_chart ($graph_data, $width, $height, $color, $legend, $long_index, $homeurl, $unit, $water_mark, $homedir, $font, $font_size, $from_ux, $from_wux) { +function flot_vcolumn_chart ($graph_data, $width, $height, $color, $legend, $long_index, $homeurl, $unit, $water_mark, $homedir, $font, $font_size, $from_ux, $from_wux, $background_color = 'white') { global $config; include_javascript_dependencies_flot_graph(); @@ -847,14 +847,14 @@ function flot_vcolumn_chart ($graph_data, $width, $height, $color, $legend, $lon if ($from_ux) { if($from_wux){ - $return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, true, true)"; + $return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, true, true, '$background_color')"; } else{ - $return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, true, false)"; + $return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, true, false, '$background_color')"; } } else { - $return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, false, false)"; + $return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, false, false, '$background_color')"; } $return .= ""; diff --git a/pandora_console/include/graphs/functions_pchart.php b/pandora_console/include/graphs/functions_pchart.php index 929a6d2fba..a265f43ede 100644 --- a/pandora_console/include/graphs/functions_pchart.php +++ b/pandora_console/include/graphs/functions_pchart.php @@ -754,13 +754,7 @@ function pch_bar_graph ($graph_type, $index, $data, $width, $height, $font, $myPicture->setGraphArea($margin_left, $margin_top, $width - $margin_right, $height - $margin_bottom); $myPicture->drawScale($scaleSettings); - /* - if (isset($legend)) { - /* Write the chart legend - $size = $myPicture->getLegendSize(array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL)); - $myPicture->drawLegend($width-$size['Width'],0,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL, "BoxWidth"=>10, "BoxHeight"=>10)); - } - */ + /* Turn on shadow computing */ $myPicture->setShadow(TRUE,array("X"=>0,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10)); diff --git a/pandora_console/include/help/en/help_alert_config.php b/pandora_console/include/help/en/help_alert_config.php index fec6b2a7bf..569242a5dc 100644 --- a/pandora_console/include/help/en/help_alert_config.php +++ b/pandora_console/include/help/en/help_alert_config.php @@ -58,6 +58,8 @@ Apart from the defined module macros, the following macros are also available:
  • _id_alert_ : Numerical ID of the alert (unique), used to correlate on third party software
  • _policy_ : Name of the policy the module belongs to (if applies).
  • _interval_ : Execution interval of the module.
  • +
  • _server_ip_ : Ip of server assigned to agent.
  • +
  • _server_name_ : Name of server assigned to agent.
  • _target_ip_ : IP address of the target of the module.
  • _target_port_ : Port number of the target of the module.
  • _plugin_parameters_ : Plug-in Parameters of the module.
  • diff --git a/pandora_console/include/help/en/help_alert_macros.php b/pandora_console/include/help/en/help_alert_macros.php index 5382c502ab..bd303e9657 100644 --- a/pandora_console/include/help/en/help_alert_macros.php +++ b/pandora_console/include/help/en/help_alert_macros.php @@ -54,6 +54,8 @@ Besides the defined module macros, the following macros are available:
  • _target_ip_: IP address for the module’s target.
  • _target_port_: Port number for the module’s target.
  • _plugin_parameters_: Module’s Plugin parameters.
  • +
  • _server_ip_ : Ip of server assigned to agent.
  • +
  • _server_name_ : Name of server assigned to agent.
  • _groupcontact_: Group’s contact information. Configured when the group is created.
  • _groupcustomid_: Group’s custom ID.
  • _groupother_: Other information about the group. Configured when the group is created.
  • diff --git a/pandora_console/include/help/es/help_alert_config.php b/pandora_console/include/help/es/help_alert_config.php index 5ab70b784e..056de9bcc3 100644 --- a/pandora_console/include/help/es/help_alert_config.php +++ b/pandora_console/include/help/es/help_alert_config.php @@ -63,6 +63,8 @@ Además de las macros de módulo definidas, las siguientes macros están disponi
  • _target_ip_ : Dirección IP del objetivo del módulo.
  • _target_port_ : Puerto del objetivo del módulo.
  • _plugin_parameters_ : Parámetros del Plug-in del módulo.
  • +
  • _server_ip_ : Ip del servidor al que el agente está asignado.
  • +
  • _server_name_ : Nombre del servidor al que el agente está asignado.
  • _groupcontact_ : Información de contacto del grupo. Se configura al crear el grupo.
  • _groupother_ : Otra información sobre el grupo. Se configura al crear el grupo.
  • _email_tag_ : Emails asociados a los tags de módulos.
  • diff --git a/pandora_console/include/help/es/help_alert_macros.php b/pandora_console/include/help/es/help_alert_macros.php index 74efb4582b..19bc0b6f71 100644 --- a/pandora_console/include/help/es/help_alert_macros.php +++ b/pandora_console/include/help/es/help_alert_macros.php @@ -54,6 +54,8 @@ Además de las macros de módulo definidas, las siguientes macros están disponi
  • _target_ip_: Dirección IP del objetivo del módulo.
  • _target_port_: Puerto del objetivo del módulo.
  • _plugin_parameters_: Parámetros del plugin del módulo.
  • +
  • _server_ip_ : Ip del servidor al que el agente está asignado.
  • +
  • _server_name_ : Nombre del servidor al que el agente está asignado.
  • _groupcontact_: Información de contacto del grupo. Se configura al crear el grupo.
  • _groupcustomid_: ID personalizado del grupo.
  • _groupother_: Otra información sobre el grupo. Se configura al crear el grupo.
  • diff --git a/pandora_console/include/help/ja/help_alert_config.php b/pandora_console/include/help/ja/help_alert_config.php index 592ed64ee3..fa6a68ffa2 100644 --- a/pandora_console/include/help/ja/help_alert_config.php +++ b/pandora_console/include/help/ja/help_alert_config.php @@ -62,6 +62,8 @@ email アクションを設定するには、_field1_ (送信先アドレス)、
  • _target_ip_ : モジュールの対象IPアドレス
  • _target_port_ : モジュールの対象ポート
  • _plugin_parameters_ : モジュールのプラグインパラメータ
  • +
  • _server_ip_ : Ip of server assigned to agent.
  • +
  • _server_name_ : Name of server assigned to agent.
  • _groupcontact_ : グループコンタクト情報。グループの作成時に設定されます。
  • _groupother_ : グループに関するその他情報。グループの作成時に設定されます。
  • _email_tag_ : モジュールタグに関連付けられた Email。
  • diff --git a/pandora_console/include/help/ja/help_alert_macros.php b/pandora_console/include/help/ja/help_alert_macros.php index c9729e6bfd..86e3a04c96 100644 --- a/pandora_console/include/help/ja/help_alert_macros.php +++ b/pandora_console/include/help/ja/help_alert_macros.php @@ -54,6 +54,8 @@
  • _target_ip_ : モジュールの対象IPアドレス
  • _target_port_ : モジュールの対象ポート
  • _plugin_parameters_ : モジュールのプラグインパラメータ
  • +
  • _server_ip_ : Ip of server assigned to agent.
  • +
  • _server_name_ : Name of server assigned to agent.
  • _groupcontact_ : グループコンタクト情報。グループの作成時に設定されます。
  • _groupcustomid_: グループカスタムID
  • _groupother_ : グループに関するその他情報。グループの作成時に設定されます。
  • diff --git a/pandora_console/include/styles/pandora.css b/pandora_console/include/styles/pandora.css index fcf084085b..beb53d61d7 100644 --- a/pandora_console/include/styles/pandora.css +++ b/pandora_console/include/styles/pandora.css @@ -769,6 +769,12 @@ input.graph_min { input.graph_min[disabled] { background: #fefefe url(../../images/chart_curve.disabled.png) no-repeat center !important; } +input.bars_graph_min { + background: #fefefe url(../../images/icono-barras-arriba.png) no-repeat center !important; +} +input.bars_graph_min[disabled] { + background: #fefefe url(../../images/icono-barras-arriba.disabled.png) no-repeat center !important; +} input.percentile_min { background: #fefefe url(../../images/chart_bar.png) no-repeat center !important; } @@ -787,6 +793,12 @@ input.auto_sla_graph_min { input.auto_sla_graph_min[disabled] { background: #fefefe url(../../images/auto_sla_graph.disabled.png) no-repeat center !important; } +input.donut_graph_min { + background: #fefefe url(../../images/icono-quesito.png) no-repeat center !important; +} +input.donut_graph_min[disabled] { + background: #fefefe url(../../images/icono-quesito.disabled.png) no-repeat center !important; +} input.binary_min { background: #fefefe url(../../images/binary.png) no-repeat center !important; } @@ -2399,29 +2411,61 @@ span#plugin_description { font-size: 14pt !important; line-height: 14pt; } +.visual_font_size_18pt, .visual_font_size_18pt > em , .visual_font_size_18pt > strong, .visual_font_size_18pt > strong > span, .visual_font_size_18pt > span, .visual_font_size_18pt > strong > em, .visual_font_size_18pt > em > strong, .visual_font_size_18pt em span, .visual_font_size_18pt span em { + font-size: 18pt !important; + line-height: 18pt; +} + .visual_font_size_24pt, .visual_font_size_24pt > em, .visual_font_size_24pt > strong, .visual_font_size_24pt > strong > span , .visual_font_size_24pt > span, .visual_font_size_24pt > strong > em, .visual_font_size_24pt > em > strong, .visual_font_size_24pt em span, .visual_font_size_24pt span em { font-size: 24pt !important; line-height: 24pt; } +.visual_font_size_28pt, .visual_font_size_28pt > em, .visual_font_size_28pt > strong, .visual_font_size_28pt > strong > span , .visual_font_size_28pt > span, .visual_font_size_28pt > strong > em, .visual_font_size_28pt > em > strong, .visual_font_size_28pt em span, .visual_font_size_28pt span em { + font-size: 28pt !important; + line-height: 28pt; +} .visual_font_size_36pt, .visual_font_size_36pt > em, .visual_font_size_36pt > strong, .visual_font_size_36pt > strong > span, .visual_font_size_36pt > span, .visual_font_size_36pt > strong > em, .visual_font_size_36pt > em > strong, .visual_font_size_36pt em span, .visual_font_size_36pt span em { font-size: 36pt !important; line-height: 36pt; } +.visual_font_size_48pt, .visual_font_size_48pt > em, .visual_font_size_48pt > strong, .visual_font_size_48pt > strong > span, .visual_font_size_48pt > span, .visual_font_size_48pt > strong > em, .visual_font_size_48pt > em > strong, .visual_font_size_48pt em span, .visual_font_size_48pt span em { + font-size: 48pt !important; + line-height: 48pt; +} +.visual_font_size_60pt, .visual_font_size_60pt > em, .visual_font_size_60pt > strong, .visual_font_size_60pt > strong > span, .visual_font_size_60pt > span, .visual_font_size_60pt > strong > em, .visual_font_size_60pt > em > strong, .visual_font_size_60pt em span, .visual_font_size_60pt span em { + font-size: 60pt !important; + line-height: 60pt; +} .visual_font_size_72pt, .visual_font_size_72pt > em, .visual_font_size_72pt > strong, .visual_font_size_72pt > strong > span, .visual_font_size_72pt > span, .visual_font_size_72pt > strong > em, .visual_font_size_72pt > em > strong, .visual_font_size_72pt em span, .visual_font_size_72pt span em { font-size: 72pt !important; line-height: 72pt; } +.visual_font_size_84pt, .visual_font_size_84pt > em, .visual_font_size_84pt > strong, .visual_font_size_84pt > strong > span, .visual_font_size_84pt > span, .visual_font_size_84pt > strong > em, .visual_font_size_84pt > em > strong, .visual_font_size_84pt em span, .visual_font_size_84pt span em { + font-size: 84pt !important; + line-height: 84pt; +} + .visual_font_size_96pt, .visual_font_size_96pt > em, .visual_font_size_96pt > strong, .visual_font_size_96pt > strong > span, .visual_font_size_96pt > span, .visual_font_size_96pt > strong > em, .visual_font_size_96pt > em > strong, .visual_font_size_96pt em span, .visual_font_size_96pt span em { font-size: 96pt !important; line-height: 96pt; } +.visual_font_size_116pt, .visual_font_size_116pt > em, .visual_font_size_116pt > strong, .visual_font_size_116pt > strong > span, .visual_font_size_116pt > span, .visual_font_size_116pt > strong > em, .visual_font_size_116pt > em > strong, .visual_font_size_116pt em span, .visual_font_size_116pt span em { + font-size: 116pt !important; + line-height: 116pt; +} + .visual_font_size_128pt, .visual_font_size_128pt > em, .visual_font_size_128pt > strong, .visual_font_size_128pt > strong > span, .visual_font_size_128pt > span, .visual_font_size_128pt > strong > em, .visual_font_size_128pt > em > strong, .visual_font_size_128pt em span, .visual_font_size_128pt span em { font-size: 128pt !important; line-height: 128pt; } +.visual_font_size_140pt, .visual_font_size_140pt > em, .visual_font_size_140pt > strong, .visual_font_size_140pt > strong > span, .visual_font_size_140pt > span, .visual_font_size_140pt > strong > em, .visual_font_size_140pt > em > strong, .visual_font_size_140pt em span, .visual_font_size_140pt span em { + font-size: 140pt !important; + line-height: 140pt; +} + .visual_font_size_154pt, .visual_font_size_154pt > em, .visual_font_size_154pt > strong, .visual_font_size_154pt > strong > span, .visual_font_size_154pt > span, .visual_font_size_154pt > strong > em, .visual_font_size_154pt > em > strong, .visual_font_size_154pt em span, .visual_font_size_154pt span em { font-size: 154pt !important; line-height: 154pt; diff --git a/pandora_console/include/styles/pandora_black.css b/pandora_console/include/styles/pandora_black.css index 9aeb56aca9..eb21ec4233 100644 --- a/pandora_console/include/styles/pandora_black.css +++ b/pandora_console/include/styles/pandora_black.css @@ -2457,29 +2457,59 @@ span#plugin_description { font-size: 14pt !important; line-height: 14pt; } +.visual_font_size_18pt, .visual_font_size_18pt > em , .visual_font_size_18pt > strong, .visual_font_size_18pt > strong > span, .visual_font_size_18pt > span, .visual_font_size_18pt > strong > em, .visual_font_size_18pt > em > strong, .visual_font_size_18pt em span, .visual_font_size_18pt span em { + font-size: 18pt !important; + line-height: 18pt; +} .visual_font_size_24pt, .visual_font_size_24pt > em, .visual_font_size_24pt > strong, .visual_font_size_24pt > strong > span , .visual_font_size_24pt > span, .visual_font_size_24pt > strong > em, .visual_font_size_24pt > em > strong, .visual_font_size_24pt em span, .visual_font_size_24pt span em { font-size: 24pt !important; line-height: 24pt; } +.visual_font_size_28pt, .visual_font_size_28pt > em, .visual_font_size_28pt > strong, .visual_font_size_28pt > strong > span , .visual_font_size_28pt > span, .visual_font_size_28pt > strong > em, .visual_font_size_28pt > em > strong, .visual_font_size_28pt em span, .visual_font_size_28pt span em { + font-size: 28pt !important; + line-height: 28pt; +} .visual_font_size_36pt, .visual_font_size_36pt > em, .visual_font_size_36pt > strong, .visual_font_size_36pt > strong > span, .visual_font_size_36pt > span, .visual_font_size_36pt > strong > em, .visual_font_size_36pt > em > strong, .visual_font_size_36pt em span, .visual_font_size_36pt span em { font-size: 36pt !important; line-height: 36pt; } +.visual_font_size_48pt, .visual_font_size_48pt > em, .visual_font_size_48pt > strong, .visual_font_size_48pt > strong > span, .visual_font_size_48pt > span, .visual_font_size_48pt > strong > em, .visual_font_size_48pt > em > strong, .visual_font_size_48pt em span, .visual_font_size_48pt span em { + font-size: 48pt !important; + line-height: 48pt; +} +.visual_font_size_60pt, .visual_font_size_60pt > em, .visual_font_size_60pt > strong, .visual_font_size_60pt > strong > span, .visual_font_size_60pt > span, .visual_font_size_60pt > strong > em, .visual_font_size_60pt > em > strong, .visual_font_size_60pt em span, .visual_font_size_60pt span em { + font-size: 60pt !important; + line-height: 60pt; +} .visual_font_size_72pt, .visual_font_size_72pt > em, .visual_font_size_72pt > strong, .visual_font_size_72pt > strong > span, .visual_font_size_72pt > span, .visual_font_size_72pt > strong > em, .visual_font_size_72pt > em > strong, .visual_font_size_72pt em span, .visual_font_size_72pt span em { font-size: 72pt !important; line-height: 72pt; } +.visual_font_size_84pt, .visual_font_size_84pt > em, .visual_font_size_84pt > strong, .visual_font_size_84pt > strong > span, .visual_font_size_84pt > span, .visual_font_size_84pt > strong > em, .visual_font_size_84pt > em > strong, .visual_font_size_84pt em span, .visual_font_size_84pt span em { + font-size: 84pt !important; + line-height: 84pt; +} .visual_font_size_96pt, .visual_font_size_96pt > em, .visual_font_size_96pt > strong, .visual_font_size_96pt > strong > span, .visual_font_size_96pt > span, .visual_font_size_96pt > strong > em, .visual_font_size_96pt > em > strong, .visual_font_size_96pt em span, .visual_font_size_96pt span em { font-size: 96pt !important; line-height: 96pt; } +.visual_font_size_116pt, .visual_font_size_116pt > em, .visual_font_size_116pt > strong, .visual_font_size_116pt > strong > span, .visual_font_size_116pt > span, .visual_font_size_116pt > strong > em, .visual_font_size_116pt > em > strong, .visual_font_size_116pt em span, .visual_font_size_116pt span em { + font-size: 116pt !important; + line-height: 116pt; +} + .visual_font_size_128pt, .visual_font_size_128pt > em, .visual_font_size_128pt > strong, .visual_font_size_128pt > strong > span, .visual_font_size_128pt > span, .visual_font_size_128pt > strong > em, .visual_font_size_128pt > em > strong, .visual_font_size_128pt em span, .visual_font_size_128pt span em { font-size: 128pt !important; line-height: 128pt; } +.visual_font_size_140pt, .visual_font_size_140pt > em, .visual_font_size_140pt > strong, .visual_font_size_140pt > strong > span, .visual_font_size_140pt > span, .visual_font_size_140pt > strong > em, .visual_font_size_140pt > em > strong, .visual_font_size_140pt em span, .visual_font_size_140pt span em { + font-size: 140pt !important; + line-height: 140pt; +} + .visual_font_size_154pt, .visual_font_size_154pt > em, .visual_font_size_154pt > strong, .visual_font_size_154pt > strong > span, .visual_font_size_154pt > span, .visual_font_size_154pt > strong > em, .visual_font_size_154pt > em > strong, .visual_font_size_154pt em span, .visual_font_size_154pt span em { font-size: 154pt !important; line-height: 154pt; @@ -2487,7 +2517,7 @@ span#plugin_description { .visual_font_size_196pt, .visual_font_size_196pt > em, .visual_font_size_196pt > strong, .visual_font_size_196pt > strong > span, .visual_font_size_196pt > span, .visual_font_size_196pt > strong > em, .visual_font_size_196pt > em > strong, .visual_font_size_196pt em span, .visual_font_size_196pt span em { font-size: 196pt !important; - line-height: 196pt; + line-height: 196pt; } diff --git a/pandora_console/include/styles/pandora_green_old.css b/pandora_console/include/styles/pandora_green_old.css index e983e6047d..a99a9a275d 100644 --- a/pandora_console/include/styles/pandora_green_old.css +++ b/pandora_console/include/styles/pandora_green_old.css @@ -2435,53 +2435,97 @@ span#plugin_description { #tinymce { text-align: left; } + .visual_font_size_4pt, .visual_font_size_4pt > em, .visual_font_size_4pt > strong, .visual_font_size_4pt > strong > span, .visual_font_size_4pt > span, .visual_font_size_4pt > strong > em, .visual_font_size_4pt > em > strong, .visual_font_size_4pt em span, .visual_font_size_4pt span em { font-size: 4pt !important; line-height: 4pt; } + .visual_font_size_6pt, .visual_font_size_6pt > em, .visual_font_size_6pt > strong, .visual_font_size_6pt > strong > span, .visual_font_size_6pt > span, .visual_font_size_6pt > strong > em, .visual_font_size_6pt > em > strong, .visual_font_size_6pt em span, .visual_font_size_6pt span em { font-size: 6pt !important; line-height: 6pt; } + .visual_font_size_8pt, .visual_font_size_8pt > em, .visual_font_size_8pt > strong, .visual_font_size_8pt > strong > span , .visual_font_size_8pt > span, .visual_font_size_8pt > strong > em, .visual_font_size_8pt > em > strong, .visual_font_size_8pt em span, .visual_font_size_8pt span em { font-size: 8pt !important; line-height: 8pt; } + .visual_font_size_10pt, .visual_font_size_10pt > em , .visual_font_size_10pt > strong, .visual_font_size_10pt > strong > em, .visual_font_size_10pt > em > strong, .visual_font_size_10pt em span, .visual_font_size_10pt span em { font-size: 10pt !important; line-height: 10pt; } + .visual_font_size_12pt, .visual_font_size_12pt > em , .visual_font_size_12pt > strong, .visual_font_size_12pt > strong > em, .visual_font_size_12pt > em > strong, .visual_font_size_12pt em span, .visual_font_size_12pt span em { font-size: 12pt !important; line-height: 12pt; } + .visual_font_size_14pt, .visual_font_size_14pt > em , .visual_font_size_14pt > strong, .visual_font_size_14pt > strong > span, .visual_font_size_14pt > span, .visual_font_size_14pt > strong > em, .visual_font_size_14pt > em > strong, .visual_font_size_14pt em span, .visual_font_size_14pt span em { font-size: 14pt !important; line-height: 14pt; } + +.visual_font_size_18pt, .visual_font_size_18pt > em , .visual_font_size_18pt > strong, .visual_font_size_18pt > strong > span, .visual_font_size_18pt > span, .visual_font_size_18pt > strong > em, .visual_font_size_18pt > em > strong, .visual_font_size_18pt em span, .visual_font_size_18pt span em { + font-size: 18pt !important; + line-height: 18pt; +} + .visual_font_size_24pt, .visual_font_size_24pt > em, .visual_font_size_24pt > strong, .visual_font_size_24pt > strong > span , .visual_font_size_24pt > span, .visual_font_size_24pt > strong > em, .visual_font_size_24pt > em > strong, .visual_font_size_24pt em span, .visual_font_size_24pt span em { font-size: 24pt !important; line-height: 24pt; } + +.visual_font_size_28pt, .visual_font_size_28pt > em, .visual_font_size_28pt > strong, .visual_font_size_28pt > strong > span , .visual_font_size_28pt > span, .visual_font_size_28pt > strong > em, .visual_font_size_28pt > em > strong, .visual_font_size_28pt em span, .visual_font_size_28pt span em { + font-size: 28pt !important; + line-height: 28pt; +} + .visual_font_size_36pt, .visual_font_size_36pt > em, .visual_font_size_36pt > strong, .visual_font_size_36pt > strong > span, .visual_font_size_36pt > span, .visual_font_size_36pt > strong > em, .visual_font_size_36pt > em > strong, .visual_font_size_36pt em span, .visual_font_size_36pt span em { font-size: 36pt !important; line-height: 36pt; } + +.visual_font_size_48pt, .visual_font_size_48pt > em, .visual_font_size_48pt > strong, .visual_font_size_48pt > strong > span, .visual_font_size_48pt > span, .visual_font_size_48pt > strong > em, .visual_font_size_48pt > em > strong, .visual_font_size_48pt em span, .visual_font_size_48pt span em { + font-size: 48pt !important; + line-height: 48pt; +} + +.visual_font_size_60pt, .visual_font_size_60pt > em, .visual_font_size_60pt > strong, .visual_font_size_60pt > strong > span, .visual_font_size_60pt > span, .visual_font_size_60pt > strong > em, .visual_font_size_60pt > em > strong, .visual_font_size_60pt em span, .visual_font_size_60pt span em { + font-size: 60pt !important; + line-height: 60pt; +} + .visual_font_size_72pt, .visual_font_size_72pt > em, .visual_font_size_72pt > strong, .visual_font_size_72pt > strong > span, .visual_font_size_72pt > span, .visual_font_size_72pt > strong > em, .visual_font_size_72pt > em > strong, .visual_font_size_72pt em span, .visual_font_size_72pt span em { font-size: 72pt !important; line-height: 72pt; } +.visual_font_size_84pt, .visual_font_size_84pt > em, .visual_font_size_84pt > strong, .visual_font_size_84pt > strong > span, .visual_font_size_84pt > span, .visual_font_size_84pt > strong > em, .visual_font_size_84pt > em > strong, .visual_font_size_84pt em span, .visual_font_size_84pt span em { + font-size: 84pt !important; + line-height: 84pt; +} + .visual_font_size_96pt, .visual_font_size_96pt > em, .visual_font_size_96pt > strong, .visual_font_size_96pt > strong > span, .visual_font_size_96pt > span, .visual_font_size_96pt > strong > em, .visual_font_size_96pt > em > strong, .visual_font_size_96pt em span, .visual_font_size_96pt span em { font-size: 96pt !important; line-height: 96pt; } +.visual_font_size_116pt, .visual_font_size_116pt > em, .visual_font_size_116pt > strong, .visual_font_size_116pt > strong > span, .visual_font_size_116pt > span, .visual_font_size_116pt > strong > em, .visual_font_size_116pt > em > strong, .visual_font_size_116pt em span, .visual_font_size_116pt span em { + font-size: 116pt !important; + line-height: 116pt; +} + .visual_font_size_128pt, .visual_font_size_128pt > em, .visual_font_size_128pt > strong, .visual_font_size_128pt > strong > span, .visual_font_size_128pt > span, .visual_font_size_128pt > strong > em, .visual_font_size_128pt > em > strong, .visual_font_size_128pt em span, .visual_font_size_128pt span em { font-size: 128pt !important; line-height: 128pt; } +.visual_font_size_140pt, .visual_font_size_140pt > em, .visual_font_size_140pt > strong, .visual_font_size_140pt > strong > span, .visual_font_size_140pt > span, .visual_font_size_140pt > strong > em, .visual_font_size_140pt > em > strong, .visual_font_size_140pt em span, .visual_font_size_140pt span em { + font-size: 140pt !important; + line-height: 140pt; +} + .visual_font_size_154pt, .visual_font_size_154pt > em, .visual_font_size_154pt > strong, .visual_font_size_154pt > strong > span, .visual_font_size_154pt > span, .visual_font_size_154pt > strong > em, .visual_font_size_154pt > em > strong, .visual_font_size_154pt em span, .visual_font_size_154pt span em { font-size: 154pt !important; line-height: 154pt; diff --git a/pandora_console/operation/agentes/graphs.php b/pandora_console/operation/agentes/graphs.php index ff1d7bf9e3..e33d499fe8 100644 --- a/pandora_console/operation/agentes/graphs.php +++ b/pandora_console/operation/agentes/graphs.php @@ -38,8 +38,8 @@ $start_date = get_parameter ("start_date", date("Y-m-d")); $draw_events = get_parameter ("draw_events", 0); $modules = get_parameter('modules', array()); $filter = get_parameter('filter', 0); -$combined = (bool)get_parameter('combined', 1); - +$combined = get_parameter('combined', 1); +$option_type = get_parameter('option_type', 0); //---------------------------------------------------------------------- // Get modules of agent sorted as: @@ -159,7 +159,6 @@ $table->data[0][1] = html_print_select($list_modules, 'modules[]', $table->rowspan[2][0] = 7; $table->data[2][0] = ""; - $table->data[2][1] = __('Begin date'); $table->data[2][2] = html_print_input_text ("start_date", substr ($start_date, 0, 10),'', 10, 40, true); $table->data[2][2] .= html_print_image ("images/calendar_view_day.png", true, array ("onclick" => "scwShow(scwID('text-start_date'),this);")); @@ -174,12 +173,17 @@ $table->data[5][2] = __('Show alerts') . ui_print_help_tip(__('the combined graph does not show the alerts into this graph'), true); $table->data[5][3] = html_print_checkbox ("draw_alerts", 1, (bool) $draw_alerts, true); $table->data[6][2] = __('Show as one combined graph'); -$table->data[6][3] = - html_print_radio_button('combined', 1, __('one combined graph'), - $combined, true); -$table->data[6][3] .= - html_print_radio_button('combined', 0, __('several graphs for each module'), - $combined, true); +$graph_option_one_or_several = array(0 => __('several graphs for each module'), 1 => __('One combined graph')); +$table->data[6][3] = html_print_select($graph_option_one_or_several, 'combined', $combined, '', '', 1, true); + +$table->data[7][2] = __('Chart type'); +if ($combined == 1) { + $graph_option_type = array(0 => __('Area'), 1 => __('Area stack'), 2 => __('Line'), 3 => __('Line stack')); +} +else { + $graph_option_type = array(0 => __('Area'), 2 => __('Line')); +} +$table->data[7][3] = html_print_select($graph_option_type, 'option_type', $option_type, '', '', 1, true); $htmlForm = ''; $htmlForm .= html_print_table($table, true); @@ -321,6 +325,39 @@ echo "
    "; // Load graphs $(document).ready(function() { + $('#combined').change(function () { + if ($('#combined').val() == 1) { + $('#option_type').empty(); + $('#option_type').append($('