From afd3322d52ba900ed5a9b39161212318098cc111 Mon Sep 17 00:00:00 2001 From: Arturo Gonzalez Date: Wed, 1 Feb 2017 11:57:10 +0100 Subject: [PATCH] Added new options to servicemap. Ticket #218 --- pandora_console/godmode/setup/setup_visuals.php | 10 ++++++++++ pandora_console/include/functions_config.php | 15 +++++++++++++++ 2 files changed, 25 insertions(+) diff --git a/pandora_console/godmode/setup/setup_visuals.php b/pandora_console/godmode/setup/setup_visuals.php index 39d075ed05..f518622353 100755 --- a/pandora_console/godmode/setup/setup_visuals.php +++ b/pandora_console/godmode/setup/setup_visuals.php @@ -112,6 +112,16 @@ $table_behaviour->data[$row][1] .= __('No') . ' ' . $row++; //Daniel maya 02/06/2016 Display menu with click --END +if (enterprise_installed()) { + $table_behaviour->data[$row][0] = __('Service label font size'); + $table_behaviour->data[$row][1] = html_print_input_text ('service_label_font_size', $config["service_label_font_size"], '', 5, 5, true); + $row++; + + $table_behaviour->data[$row][0] = __('Service item padding size'); + $table_behaviour->data[$row][1] = html_print_input_text ('service_item_padding_size', $config["service_item_padding_size"], '', 5, 5, true); + $row++; +} + echo "
"; echo "" . __('Behaviour configuration') . ""; html_print_table ($table_behaviour); diff --git a/pandora_console/include/functions_config.php b/pandora_console/include/functions_config.php index 2ff6704d53..8e3e3e4e67 100644 --- a/pandora_console/include/functions_config.php +++ b/pandora_console/include/functions_config.php @@ -534,6 +534,12 @@ function config_update_config () { if (!config_update_value ('click_display', (bool) get_parameter('click_display', false))) $error_update[] = __('Display lateral menus with left click'); //Daniel maya 02/06/2016 Display menu with click --END + if (isset($config['enterprise_installed']) && $config['enterprise_installed'] == 1) { + if (!config_update_value ('service_label_font_size', get_parameter('service_label_font_size', false))) + $error_update[] = __('Service label font size'); + if (!config_update_value ('service_item_padding_size', get_parameter('service_item_padding_size', false))) + $error_update[] = __('Service item padding size'); + } if (!config_update_value ('percentil', (int) get_parameter('percentil', 0))) $error_update[] = __('Default percentil'); @@ -1540,6 +1546,15 @@ function config_process_config () { config_update_value ('click_display', 1); } //Daniel maya 02/06/2016 Display menu with click --END + if (isset($config['enterprise_installed']) && $config['enterprise_installed'] == 1) { + if (!isset($config["service_label_font_size"])) { + config_update_value ('service_label_font_size', 11); + } + + if (!isset($config["service_item_padding_size"])) { + config_update_value ('service_item_padding_size', 0); + } + } if (!isset($config['command_snapshot'])) { config_update_value ('command_snapshot', 1); }