From 39ace106296008af33212072efc6c2f1546237d8 Mon Sep 17 00:00:00 2001 From: Jose Gonzalez Date: Sat, 11 Mar 2023 02:08:37 +0100 Subject: [PATCH 01/23] Fix image issue with Networkmap --- pandora_console/operation/agentes/pandora_networkmap.editor.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pandora_console/operation/agentes/pandora_networkmap.editor.php b/pandora_console/operation/agentes/pandora_networkmap.editor.php index 4450e101ea..14d04dcc60 100644 --- a/pandora_console/operation/agentes/pandora_networkmap.editor.php +++ b/pandora_console/operation/agentes/pandora_networkmap.editor.php @@ -275,7 +275,7 @@ if ($not_found) { } else { if ($disabled_source === false) { echo '
'; - echo html_print_image('images/spinner.gif', true, 'width: 50px;height: 50px;'); + echo html_print_image('images/spinner.gif', true, ['width' => '50px', 'height' => '50px']); echo '
'.__('Creating map...').'
'; echo '
'; $info1 = __('To create a network map that visually recreates link-level (L2) relationships, you must first discover these relationships with Discovery Server. Network maps only reflect relationships that have already been discovered.'); From f553019a404e2ad075e1cde7a99f4305dfb46d7c Mon Sep 17 00:00:00 2001 From: Jose Gonzalez Date: Sat, 11 Mar 2023 02:10:16 +0100 Subject: [PATCH 02/23] Minor fixes --- pandora_console/include/styles/pandora.css | 1 + pandora_console/include/styles/pandora_black.css | 14 +++++++------- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/pandora_console/include/styles/pandora.css b/pandora_console/include/styles/pandora.css index 5a340c3218..f3a2e32799 100644 --- a/pandora_console/include/styles/pandora.css +++ b/pandora_console/include/styles/pandora.css @@ -11262,6 +11262,7 @@ span.subsection_header_title { span.subsection_header_title.secondary { height: 14px; + line-height: 14px; } .regular_font { diff --git a/pandora_console/include/styles/pandora_black.css b/pandora_console/include/styles/pandora_black.css index 9a0a6ac63e..94c87cd1fc 100644 --- a/pandora_console/include/styles/pandora_black.css +++ b/pandora_console/include/styles/pandora_black.css @@ -1111,6 +1111,7 @@ select, border: 1px solid #707070; background-color: #222 !important; color: #fff !important; + border-radius: 0; } .white_table_graph { @@ -1475,13 +1476,6 @@ span.select2-dropdown.select2-dropdown--below { z-index: 1200; } -div.fixed_filter_bar, -div.white_table_graph_header { - border-radius: 0; - border-left: 0px; - border-right: 0px; -} - div.white_table_graph { border-radius: 0; } @@ -1502,3 +1496,9 @@ table.filter-table-adv td > div label { #principal_action_buttons { background: #111111; } +div.fixed-bottom-box, +div.fixed-bottom-box + > div.fixed-bottom-box-head + > div.fixed-bottom-box-head-body { + background-color: #111111 !important; +} From bbec6a92a4c065c49d41f82a1d98f1402a334ca8 Mon Sep 17 00:00:00 2001 From: Jose Gonzalez Date: Mon, 13 Mar 2023 09:35:12 +0100 Subject: [PATCH 03/23] Minor fixes --- pandora_console/godmode/category/category.php | 5 +---- pandora_console/include/functions_treeview.php | 12 ++++++------ pandora_console/include/functions_ui.php | 14 ++++++++++---- 3 files changed, 17 insertions(+), 14 deletions(-) diff --git a/pandora_console/godmode/category/category.php b/pandora_console/godmode/category/category.php index aa3a23778d..935d2c1d5d 100755 --- a/pandora_console/godmode/category/category.php +++ b/pandora_console/godmode/category/category.php @@ -262,10 +262,7 @@ if ($is_management_allowed === true) { [ 'icon' => 'next' ], true ), - [ - 'type' => 'form_action', - 'right_content' => $tablePagination, - ] + [ 'right_content' => $tablePagination ] ); echo ''; diff --git a/pandora_console/include/functions_treeview.php b/pandora_console/include/functions_treeview.php index e93910ec15..86367a1097 100755 --- a/pandora_console/include/functions_treeview.php +++ b/pandora_console/include/functions_treeview.php @@ -727,8 +727,8 @@ function treeview_printTable($id_agente, $server_data=[], $no_head=false) false, false, '', - 'white-box-content', - 'white_table_flex margin-bottom-10 border-bottom-gray' + 'white-box-content mrgn_top_0 mrgn_btn_0px', + 'white_table_flex' ); if ($config['agentaccess']) { @@ -747,8 +747,8 @@ function treeview_printTable($id_agente, $server_data=[], $no_head=false) true, false, '', - 'white-box-content border-bottom-gray', - 'white_table_flex margin-top-10 margin-bottom-10' + 'white-box-content mrgn_top_0 mrgn_btn_0px border-bottom-gray', + 'white_table_flex' ); } @@ -920,8 +920,8 @@ function treeview_printTable($id_agente, $server_data=[], $no_head=false) true, false, '', - 'white-box-content border-bottom-gray', - 'white_table_flex margin-top-10 margin-bottom-10' + 'white-box-content mrgn_top_0 mrgn_btn_0px border-bottom-gray', + 'white_table_flex' ); if (empty($server_data) === false && is_metaconsole() === true) { diff --git a/pandora_console/include/functions_ui.php b/pandora_console/include/functions_ui.php index d272ee224a..8df6dc2fa1 100755 --- a/pandora_console/include/functions_ui.php +++ b/pandora_console/include/functions_ui.php @@ -4327,7 +4327,10 @@ function ui_toggle( $image_a = html_print_image( $img_a, true, - [ 'style' => 'rotate: '.$rotateA ], + [ + 'class' => 'mrgn_right_10px', + 'style' => 'rotate: '.$rotateA, + ], true ); } else { @@ -4338,7 +4341,10 @@ function ui_toggle( $image_b = html_print_image( $img_b, true, - [ 'style' => 'rotate: '.$rotateB ], + [ + 'class' => 'mrgn_right_10px', + 'style' => 'margin-right:10px; rotate: '.$rotateB, + ], true ); } else { @@ -4401,7 +4407,7 @@ function ui_toggle( $original, true, [ - 'class' => 'float-left main_menu_icon', + 'class' => 'float-left main_menu_icon mrgn_right_10px', 'style' => 'object-fit: contain; margin-right:10px; rotate:'.$imageRotate, 'title' => $title, 'id' => 'image_'.$uniqid, @@ -4433,7 +4439,7 @@ function ui_toggle( $original, true, [ - 'class' => 'main_menu_icon', + 'class' => 'main_menu_icon mrgn_right_10px', 'style' => 'object-fit: contain; float:right; margin-right:10px; rotate:'.$imageRotate, 'title' => $title, 'id' => 'image_'.$uniqid, From 80076434b34d44b73eda55b180a457efb90cab93 Mon Sep 17 00:00:00 2001 From: Jonathan Date: Mon, 13 Mar 2023 10:29:03 +0100 Subject: [PATCH 04/23] SNMP visual fix staticts --- .../include/class/SnmpConsole.class.php | 140 +++++------------- pandora_console/include/functions_ui.php | 9 +- pandora_console/include/styles/pandora.css | 18 +++ .../operation/snmpconsole/snmp_statistics.php | 29 ++-- 4 files changed, 79 insertions(+), 117 deletions(-) diff --git a/pandora_console/include/class/SnmpConsole.class.php b/pandora_console/include/class/SnmpConsole.class.php index ec7e3394dd..f1895dfc51 100644 --- a/pandora_console/include/class/SnmpConsole.class.php +++ b/pandora_console/include/class/SnmpConsole.class.php @@ -181,113 +181,47 @@ class SnmpConsole extends HTML $default_refr = 300; - if (!isset($config['pure']) || $config['pure'] === false) { - $statistics['text'] = ''.html_print_image( - 'images/logs@svg.svg', - true, - [ - 'title' => __('Statistics'), - 'class' => 'main_menu_icon invert_filter', - ] - ).''; - $list['text'] = ''.html_print_image( - 'images/SNMP-network-numeric-data@svg.svg', - true, - [ - 'title' => __('List'), - 'class' => 'main_menu_icon invert_filter', - ] - ).''; - $list['active'] = true; + $statistics['text'] = ''.html_print_image( + 'images/logs@svg.svg', + true, + [ + 'title' => __('Statistics'), + 'class' => 'main_menu_icon invert_filter', + ] + ).''; + $list['text'] = ''.html_print_image( + 'images/SNMP-network-numeric-data@svg.svg', + true, + [ + 'title' => __('List'), + 'class' => 'main_menu_icon invert_filter', + ] + ).''; + $list['active'] = true; - $screen['text'] = ''.html_print_image( - 'images/fullscreen@svg.svg', - true, + // Header. + ui_print_standard_header( + __('SNMP Console'), + 'images/op_snmp.png', + false, + 'snmp_console', + false, + [ + $screen, + $list, + $statistics, + ], + [ [ - 'title' => __('View in full screen'), - 'class' => 'main_menu_icon invert_filter', - ] - ).''; - - // Header. - ui_print_standard_header( - __('SNMP Console'), - 'images/op_snmp.png', - false, - 'snmp_console', - false, - [ - $screen, - $list, - $statistics, + 'link' => '', + 'label' => __('Monitoring'), ], [ - [ - 'link' => '', - 'label' => __('Monitoring'), - ], - [ - 'link' => '', - 'label' => __('SNMP'), - ], - ] - ); - } else { - echo '
'; - - echo ''; - - echo '
'; - - ui_require_css_file('pandora_enterprise', ENTERPRISE_DIR.'/include/styles/'); - ui_require_css_file('pandora_dashboard', ENTERPRISE_DIR.'/include/styles/'); - ui_require_css_file('cluetip', 'include/styles/js/'); - - ui_require_jquery_file('countdown'); - ui_require_javascript_file('pandora_dashboard', ENTERPRISE_DIR.'/include/javascript/'); - ui_require_javascript_file('wz_jsgraphics'); - ui_require_javascript_file('pandora_visual_console'); - } + 'link' => '', + 'label' => __('SNMP'), + ], + ] + ); // Datatables list. try { diff --git a/pandora_console/include/functions_ui.php b/pandora_console/include/functions_ui.php index d272ee224a..5a19b69da3 100755 --- a/pandora_console/include/functions_ui.php +++ b/pandora_console/include/functions_ui.php @@ -5044,6 +5044,8 @@ function ui_print_page_header( $breadcrumbs='', $hide_left_small=false ) { + global $config; + $title = io_safe_input_html($title); if (($icon == '') && ($godmode == true)) { $icon = 'images/gm_setup.png'; @@ -5057,13 +5059,18 @@ function ui_print_page_header( $type = 'view'; $type2 = 'menu_tab_frame_view'; $separator_class = 'separator'; + $div_style = ''; } else { $type = 'view'; $type2 = 'menu_tab_frame_view'; $separator_class = 'separator_view'; + $div_style = ''; + if ($config['pure'] === true) { + $div_style = 'top:0px;'; + } } - $buffer = '
'; + $buffer = '
'; if (!empty($breadcrumbs)) { $buffer .= '