From 5e8478b5feef2ba905e5ed3b553df8ce1075c459 Mon Sep 17 00:00:00 2001 From: zarzuelo Date: Thu, 11 Aug 2011 18:06:54 +0000 Subject: [PATCH] 2011-08-11 Sergio Martin * include/config_process.php godmode/setup/setup_visuals.php: Fixed flash charts setup editor and user editor and set priority between both git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4722 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 6 ++++++ pandora_console/godmode/setup/setup_visuals.php | 4 ++-- pandora_console/include/config_process.php | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 0db6ec792b..4a4420132d 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,9 @@ +2011-08-11 Sergio Martin + + * include/config_process.php + godmode/setup/setup_visuals.php: Fixed flash charts setup editor + and user editor and set priority between both + 2011-08-11 Sergio Martin * include/functions_graph.php diff --git a/pandora_console/godmode/setup/setup_visuals.php b/pandora_console/godmode/setup/setup_visuals.php index 51c89cfdd5..ae6fce45a6 100644 --- a/pandora_console/godmode/setup/setup_visuals.php +++ b/pandora_console/godmode/setup/setup_visuals.php @@ -86,8 +86,8 @@ $table->data[11][0] = __('Font size'); $table->data[11][1] = html_print_select(range(1, 15), 'font_size', $config["font_size"], '', '', 0, true); $table->data[12][0] = __('Flash charts'); -$table->data[12][1] = __('Yes').' '.html_print_radio_button ('flash_charts', 1, '', $config["flash_charts"], true).'  '; -$table->data[12][1] .= __('No').' '.html_print_radio_button ('flash_charts', 0, '', $config["flash_charts"], true); +$table->data[12][1] = __('Yes').' '.html_print_radio_button ('flash_charts', 1, '', $config["global_flash_charts"], true).'  '; +$table->data[12][1] .= __('No').' '.html_print_radio_button ('flash_charts', 0, '', $config["global_flash_charts"], true); if (!defined ('PANDORA_ENTERPRISE')){ $table->data[13][0] = __('Custom logo') . ui_print_help_icon("custom_logo", true); diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php index 126ce40344..aef8db9909 100644 --- a/pandora_console/include/config_process.php +++ b/pandora_console/include/config_process.php @@ -95,8 +95,9 @@ if ((!isset($config["timezone"])) OR ($config["timezone"] == "")){ date_default_timezone_set($config["timezone"]); -// Save the global block size +// Save the global values $config["global_block_size"] = $config["block_size"]; +$config["global_flash_charts"] = $config["flash_charts"]; if (isset ($config['id_user'])){ $userinfo = get_user_info ($config['id_user']); @@ -104,8 +105,10 @@ if (isset ($config['id_user'])){ // If block_size or flash_chart are provided then override global settings if (!empty($userinfo["block_size"]) && ($userinfo["block_size"] != 0)) $config["block_size"] = $userinfo["block_size"]; + if ($userinfo["flash_chart"] != -1) $config["flash_charts"] = $userinfo["flash_chart"]; + html_debug_print($config["flash_charts"]); // Each user could have it's own timezone) if (isset($userinfo["timezone"])) {