From ab54a2681588deb1946a3ce9f4cc5a699349deef Mon Sep 17 00:00:00 2001 From: Pablo Aragon Date: Thu, 29 Dec 2022 16:21:36 +0100 Subject: [PATCH] 9868 Remove footer and create About section --- pandora_console/godmode/menu.php | 9 + .../images/menu/about.menu_gray.png | Bin 0 -> 759 bytes .../images/menu/about.menu_white.png | Bin 0 -> 563 bytes pandora_console/include/functions_menu.php | 289 ++++++++++++++++++ pandora_console/include/javascript/pandora.js | 55 ++++ pandora_console/include/styles/menu.css | 6 + pandora_console/include/styles/pandora.css | 89 ++++++ pandora_console/index.php | 54 +--- 8 files changed, 451 insertions(+), 51 deletions(-) create mode 100644 pandora_console/images/menu/about.menu_gray.png create mode 100644 pandora_console/images/menu/about.menu_white.png diff --git a/pandora_console/godmode/menu.php b/pandora_console/godmode/menu.php index 7d26d69d2a..1fbeea6253 100644 --- a/pandora_console/godmode/menu.php +++ b/pandora_console/godmode/menu.php @@ -1,4 +1,5 @@ '; diff --git a/pandora_console/images/menu/about.menu_gray.png b/pandora_console/images/menu/about.menu_gray.png new file mode 100644 index 0000000000000000000000000000000000000000..35b2c34ad4ac16d498de072c09ec57337ca69f05 GIT binary patch literal 759 zcmeAS@N?(olHy`uVBq!ia0vp^5+KaM#=yWhy?{3l$YDu$^mSxl*x1kgCy^D%w@8if zO!M_+&;qhK7#Q0#8CZZUMj(~~Vg?4L1x#=ei3Q9EHc0Z|-|*=`C0U*>jv*erXG8Y} zi8u<(i(@Hrda95h{JENw<4K*DZFftD`2iyXl?6|Dd31~eU+3{N)pnlNU1bnZcaKps z?@j)+{B8L&RX2E@=G#{Nt9;r2YnIGRzYcHsa6r<|Q(%S8j-%J~%S*+s{QBElEco5l z;={f4_QfB0bK}447TR)xh1qEbCky|90^=8@#TPs~mQCq8ad5%)%9W1&^O{!b?PGfF zTGnX%eEEBa758})oTjbcHmzcV#gQK-GUfSmDM>R%XYbi?!859^hzcF znRM+jZ*j|}Q`X7;x~Ts*Mv zpjN}RWiu{6o6*D<>E!w|!Qi9A6(*AgUM?#MgX0Md0nAqx*-VWui;ZO0&RnuJR%8;J zM$}&4)AzCrJlH2bmSAL_8n$Z3i>NtCQMu_#&J|m}=htZBDza4O85d^;_hMC)zGxNM32*K9eh$ji>#VRpZhvqGvDcNU(gA$IWES zW%chhEx*F3#ALpL+`zvN$OSs~t#ZsVA4Q0nt^^>bP0l+XkKBojS8 literal 0 HcmV?d00001 diff --git a/pandora_console/images/menu/about.menu_white.png b/pandora_console/images/menu/about.menu_white.png new file mode 100644 index 0000000000000000000000000000000000000000..d3913b87cf1f5f854ac4ef577fe348b1af1c6a96 GIT binary patch literal 563 zcmeAS@N?(olHy`uVBq!ia0vp^5+KaM#=yWhy?{3l$YDu$^mSxl*x1kgCy^D%w@8if zO!M_+&;qhK7#Q0#8CZZUMj(~~Vg?4L1x#=ei3Q9EHc0Z|-|*=`#mhWh978;KuZ9}> zF+1|?aq;qW?)=0f=hXG5L+ihXeBcKzyM_|gN6ZVIInrvjZLHmW@uJJ2OY^ROyAfx7 z@2mk!RN;SKrTEX6)tnrn>ty=>W-z|^ow`qZ0;{m9s7crEg&G>Y%U%~ZYuR%M9f}h@ z&t`CVCKuPm1HpH>7JX$b62GX+bJ*~?wpg&tMl)N59KYzMm|14lqPIH9ku4xJsa6NI&~&_oMMzY;r>Rm2mc>f*ezcgIw|Z~&y1(3Om}8S?rz@ta9-!WyWb9;m|gtx$ftJ( z3lUkX>&Uu?Wm(X)i%z3){xvXc literal 0 HcmV?d00001 diff --git a/pandora_console/include/functions_menu.php b/pandora_console/include/functions_menu.php index 8b1f1deaae..a126cf5d03 100644 --- a/pandora_console/include/functions_menu.php +++ b/pandora_console/include/functions_menu.php @@ -772,3 +772,292 @@ function menu_pepare_acl_select_data($pages, $sec) return $pages; } + + +if (is_ajax()) { + $about = (bool) get_parameter('about'); + if ($about) { + global $config; + global $pandora_version; + global $build_version; + $product_name = io_safe_output(get_product_name()); + + include_once $config['homedir'].'/include/class/Diagnostics.class.php'; + $d = new Diagnostics; + $db_health = json_decode($d->getDatabaseHealthStatus()); + $db_info = json_decode($d->getDatabaseStatusInfo()); + $db_fragmentation = json_decode($d->getTablesFragmentation()); + $sys_info = json_decode($d->getSystemInfo()); + $php_sys = json_decode($d->getPHPSetup()); + + $fragmentation_status = ''; + if ($db_fragmentation->data->tablesFragmentationStatus->status === 1) { + $fragmentation_status = html_print_image( + 'images/exito.png', + true, + [ + 'title' => __('Successfully'), + 'style' => 'width:15px;', + ] + ); + } else { + $fragmentation_status = html_print_image( + 'images/error_1.png', + true, + [ + 'title' => __('Error'), + 'style' => 'width:15px;', + ] + ); + } + + $dialog = ' + + '; + + echo $dialog; + } +} diff --git a/pandora_console/include/javascript/pandora.js b/pandora_console/include/javascript/pandora.js index 91446d1464..03a2ec8fe3 100644 --- a/pandora_console/include/javascript/pandora.js +++ b/pandora_console/include/javascript/pandora.js @@ -2241,3 +2241,58 @@ var formatterDataVerticalBar = function(value, ctx) { return percentage; } }; + +// Show about section +$(document).ready(function() { + $("#icon_about").click(function() { + $("#icon_about").addClass("selected"); + + jQuery.post( + "ajax.php", + { + page: "include/functions_menu", + about: "true" + }, + function(data) { + $("div.ui-dialog").remove(); + $("#about-div").html(""); + if (data) { + $("#about-div").html(data); + openAbout(); + } + }, + "html" + ); + }); + + function openAbout() { + $("#about-tabs").dialog({ + // title: "About", + resizable: false, + draggable: false, + modal: true, + show: { + effect: "fade", + duration: 200 + }, + hide: { + effect: "fade", + duration: 200 + }, + closeOnEscape: true, + width: 700, + height: 450, + + create: function() { + $("#about-tabs").tabs({}); + $(".ui-dialog-titlebar").remove(); + + $("#about-close").click(function() { + $("#about-tabs").dialog("close"); + $("div.ui-dialog").remove(); + $("#icon_about").removeClass("selected"); + }); + } + }); + } +}); diff --git a/pandora_console/include/styles/menu.css b/pandora_console/include/styles/menu.css index 7348875a45..d59f802498 100644 --- a/pandora_console/include/styles/menu.css +++ b/pandora_console/include/styles/menu.css @@ -212,6 +212,9 @@ li.sub_subMenu.selected { #icon_god-module_library { background-image: url(../../images/menu/gm_library.menu_gray.png); } +#icon_about { + background-image: url(../../images/menu/about.menu_gray.png); +} #menu_container { z-index: 3; @@ -375,6 +378,9 @@ ul li { .selected#icon_god-module_library { background-image: url(../../images/menu/gm_library.menu_white.png); } +.selected#icon_about { + background-image: url(../../images/menu/about.menu_white.png); +} #menu_full { height: 100%; diff --git a/pandora_console/include/styles/pandora.css b/pandora_console/include/styles/pandora.css index 625aabeeef..8dbe2c03e5 100644 --- a/pandora_console/include/styles/pandora.css +++ b/pandora_console/include/styles/pandora.css @@ -9169,3 +9169,92 @@ div#err_msg_centralised { justify-content: start; padding-left: 10px; } + +/* Table about dialog */ +.table-about { + background-color: white !important; + width: 100%; + border-collapse: collapse; +} + +.table-about th { + background-color: white !important; + width: 100%; +} + +.table-about h1 { + text-transform: none !important; + font-size: 28px !important; + color: #454545; + margin-top: 34px; + margin-left: 9px; +} + +.table-about h2 { + text-transform: none !important; + font-size: 15px !important; + margin-bottom: 5px; + margin-left: 9px; + color: #14524f; +} + +.table-about h2 span { + color: #14524f; + font-size: large; + font-weight: bolder; +} + +.table-about p { + color: #454545; + font-size: 15px; + font-weight: normal; + margin: 7px; + margin-left: 9px; +} + +.table-about p span { + color: #454545; + font-size: 15px; + font-weight: bold; + margin: 9px; + margin-left: 0px; +} + +.table-about p.about-last-p { + padding-bottom: 17px; +} + +.table-about .about-last-tr { + border-bottom: 1px solid #eaeaea; +} + +.about-copyright-div { + width: 100%; + height: 100%; +} + +p.trademark-copyright { + width: 90%; + color: #8a96a6; + font-size: 13px; + margin-top: 20px; + margin-bottom: 0px; + text-align: center !important; + position: absolute; + bottom: 0; +} + +#about-tabs, +#tab-general-view { + padding-bottom: 0px; + margin-bottom: 0px; +} + +#about-tabs { + overflow: hidden; +} + +#tab-database { + height: 80%; + overflow: auto; +} diff --git a/pandora_console/index.php b/pandora_console/index.php index 32db58241a..c712be0567 100755 --- a/pandora_console/index.php +++ b/pandora_console/index.php @@ -227,6 +227,9 @@ ob_start('ui_process_page_head'); // Enterprise main. enterprise_include_once('index.php'); +// Load event.css to display the about section dialog with correct styles. +echo ''; + echo '