diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index adeb56436d..62f5a9762b 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,18 @@ +2012-04-25 Juan Manuel Ramon + + * include/styles/dialog.css + index.php: Added support for new login help modal window. + + * general/login_help_dialog.php: New login help modal window. + + * include/functions_ui.php + general/logoff.php: Added required javascript files. + + * extensions/update_manager.php: Changed license modal + window style to Chrome box model. + + Merged from branches. + 2012-04-25 Miguel de Dios * include/functions_api.php, include/api.php: fixed when some error diff --git a/pandora_console/extensions/update_manager.php b/pandora_console/extensions/update_manager.php index 0c24241963..27bcd0b065 100644 --- a/pandora_console/extensions/update_manager.php +++ b/pandora_console/extensions/update_manager.php @@ -52,7 +52,7 @@ if (is_ajax ()) { $table->style = array(); $table->style[0] = 'text-align: left'; - echo '
'; + echo '
'; html_print_image('images/noaccess.png', false); echo '
'; @@ -66,7 +66,7 @@ if (is_ajax ()) { $table->data[3][0] = ''.__('License Mode').''; $table->data[3][1] = __('Open Source Version'); - echo '
'; + echo '
'; html_print_table ($table); echo '
'; } diff --git a/pandora_console/general/login_help_dialog.php b/pandora_console/general/login_help_dialog.php new file mode 100644 index 0000000000..d5b986f6df --- /dev/null +++ b/pandora_console/general/login_help_dialog.php @@ -0,0 +1,144 @@ + 1), array("token" => "skip_login_help_dialog")); + else + $result_config = db_process_sql_insert ('tconfig', array ("value" => 1, "token" => "skip_login_help_dialog")); + } + + return; +} + +// Prints help dialog information + +echo '
'; + + echo '
'; + echo '' . __('If this is your first time with Pandora FMS, we propose you a few links to learn more about Pandora FMS. Monitoring could be overhelm, but take your time to learn how to use the power of Pandora!') . ''; + echo '
'; + + echo '
'; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo '
'; + echo '
'; + echo html_print_image('images/noaccess.png', true, array("alt" => __('Online help'), "border" => 0)); + echo '
'; + echo '
'; + echo '' . __('Online help') . ''; + echo '
'; + echo '
'; + echo '
'; + echo html_print_image('images/noaccess.png', true, array("alt" => __('Support'), "border" => 0)); + echo '
'; + echo ''; + echo '
'; + echo '
'; + echo html_print_image('images/noaccess.png', true, array("alt" => __('Enterprise version'), "border" => 0)); + echo '
'; + echo '
'; + echo '' . __('Enterprise version') . ''; + echo '
'; + echo '
'; + echo '
'; + echo html_print_image('images/noaccess.png', true, array("alt" => __('Documentation'), "border" => 0)); + echo '
'; + echo '
'; + echo '' . __('Documentation') . ''; + echo '
'; + echo '
'; + echo '
'; + + echo '
'; + echo '
'; + html_print_checkbox('skip_login_help', 1, false, false, false, 'cursor: \'pointer\''); + echo ' ' .__("Click here to don't show again this message") . ''; + echo '
'; + echo '
'; + html_print_submit_button("Ok", 'hide-login-help', false, 'class="ui-button-dialog ui-widget ui-state-default ui-corner-all ui-button-text-only" style="width:100px;"'); + echo '
'; + echo '
'; + +echo '
'; + +ui_require_css_file ('dialog'); +ui_require_jquery_file ('ui.core'); +ui_require_jquery_file ('ui.dialog'); +ui_require_jquery_file ('ui.draggable'); + +?> + + diff --git a/pandora_console/general/logoff.php b/pandora_console/general/logoff.php index 60c7e7bce1..baad8e4e7f 100644 --- a/pandora_console/general/logoff.php +++ b/pandora_console/general/logoff.php @@ -14,6 +14,11 @@ // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. +ui_require_css_file ('dialog'); +ui_require_jquery_file ('ui.core'); +ui_require_jquery_file ('ui.dialog'); +ui_require_jquery_file ('ui.draggable'); + ?>
diff --git a/pandora_console/include/functions_ui.php b/pandora_console/include/functions_ui.php index f2bd2d994b..28c85b3bdb 100644 --- a/pandora_console/include/functions_ui.php +++ b/pandora_console/include/functions_ui.php @@ -1166,6 +1166,8 @@ function ui_process_page_head ($string, $bitfield) { $black_list_pages_old_jquery = array('operation/gis_maps/index'); if (in_array(get_parameter('sec2'), $black_list_pages_old_jquery)) { $config['jquery'] = array_merge (array ("jquery" => "include/javascript/jquery.js", + "ui" => "include/javascript/jquery.ui.core.js", + "dialog" => "include/javascript/jquery.ui.dialog.js", "pandora" => "include/javascript/jquery.pandora.js"), $config['jquery']); } diff --git a/pandora_console/include/styles/dialog.css b/pandora_console/include/styles/dialog.css index c42c252c59..3b247a7465 100644 --- a/pandora_console/include/styles/dialog.css +++ b/pandora_console/include/styles/dialog.css @@ -2,7 +2,7 @@ /* This file skins dialog */ .ui-dialog { - background: none repeat scroll 0 0 #D3D3D3 !important; + background: none repeat scroll 0 0 #b0d68d !important; border: 1px solid #DDDDDD !important; color: #333333 !important; padding: 0.2em !important; @@ -20,16 +20,16 @@ .ui-dialog .ui-dialog-titlebar { background: url(../../images/ui_title.png) repeat-x scroll !important; - #height: 15px !important; + height: 14px !important; #_height: 16px !important; padding: 0.3em 1em !important; position:relative; margin: 0px auto 0 auto !important; font-weight: bold !important; - border-bottom: 1px solid #A9A9A9 !important; - border-top: 1px solid #A9A9A9 !important; - border-left: 1px solid #A9A9A9 !important; - border-right: 1px solid #A9A9A9 !important; + border-bottom: none !important; + border-top: none !important; + border-left: none !important; + border-right: none !important; color: #FFFFFF !important; #padding: 0.1em 1em !important; diff --git a/pandora_console/index.php b/pandora_console/index.php index fd5509f15c..b632b54ab4 100644 --- a/pandora_console/index.php +++ b/pandora_console/index.php @@ -319,6 +319,18 @@ if ($old_global_counter_chat != $now_global_counter_chat) { $_SESSION['new_chat'] = true; } +// Display login help info dialog +if (get_parameter ('login', 0) == 1) { + + // If it's configured to not skip this + if (!isset($config['skip_login_help_dialog']) or $config['skip_login_help_dialog'] == 0) { + + include_once("general/login_help_dialog.php"); + + } + +} + // Header if ($config["pure"] == 0) { echo '