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 0000000000..35b2c34ad4 Binary files /dev/null and b/pandora_console/images/menu/about.menu_gray.png differ 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 0000000000..d3913b87cf Binary files /dev/null and b/pandora_console/images/menu/about.menu_white.png differ 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 = ' +
+ |
+
+ '.$product_name.'+'.__('Version').' '.$pandora_version.' - '.(enterprise_installed() ? 'Enterprise' : 'Community').' +'.__('MR version').' MR'.$config['MR'].' +'.__('Build').' '.$build_version.' +'.__('Support expires').' 2023/04/26 '; + if ((bool) check_acl($config['id_user'], 0, 'PM') === true) { + $dialog .= ' +
+
+
+
+ ';
+ }
+
+ $dialog .= ' |
+
---|
Trademark and copyright 2004 - '.date('Y').' Pandora FMS. All rights reserved
+
+ - '.__('Database health status').'+ |
+ |
---|---|
+ '.$db_health->data->unknownAgents->name.' + |
+
+ '.$db_health->data->unknownAgents->value.' + |
+
+ '.$db_health->data->notInitAgents->name.' + |
+
+ '.$db_health->data->notInitAgents->value.' + |
+
+ '.$db_health->data->pandoraDbLastRun->name.' + |
+
+ '.$db_health->data->pandoraDbLastRun->value.' + |
+
+ - '.__('Database status info').'+ |
+ |
+ '.$db_info->data->dbSchemeFirstVersion->name.' + |
+
+ '.$db_info->data->dbSchemeFirstVersion->value.' + |
+
+ '.$db_info->data->dbSchemeVersion->name.' + |
+
+ '.$db_info->data->dbSchemeVersion->value.' + |
+
+ '.$db_info->data->dbSchemeBuild->name.' + |
+
+ '.$db_info->data->dbSchemeBuild->value.' + |
+
+ '.$db_info->data->dbSize->name.' + |
+
+ '.$db_info->data->dbSize->value.' + |
+
+ - '.__('Tables fragmentation in the %s database', $product_name).'+ |
+ |
+ '.$db_fragmentation->data->tablesFragmentationMax->name.' + |
+
+ '.$db_fragmentation->data->tablesFragmentationMax->value.' + |
+
+ '.$db_fragmentation->data->tablesFragmentationValue->name.' + |
+
+ '.$db_fragmentation->data->tablesFragmentationValue->value.' + |
+
+ '.$db_fragmentation->data->tablesFragmentationStatus->name.' + |
+
+ '.$fragmentation_status.' + |
+
+ - '.__('System Info').'+ |
+ |
---|---|
+ '.$sys_info->data->cpuInfo->name.' + |
+
+ '.$sys_info->data->cpuInfo->value.' + |
+
+ '.$sys_info->data->ramInfo->name.' + |
+
+ '.$sys_info->data->ramInfo->value.' + |
+
+ '.$sys_info->data->osInfo->name.' + |
+
+ '.$sys_info->data->osInfo->value.' + |
+
+ '.$sys_info->data->hostnameInfo->name.' + |
+
+ '.$sys_info->data->hostnameInfo->value.' + |
+
+ '.$sys_info->data->ipInfo->name.' + |
+
+ '.$sys_info->data->ipInfo->value.' + |
+
+ - '.__('PHP system').'+ |
+ |
---|---|
+ '.$php_sys->data->phpVersion->name.' + |
+
+ '.$php_sys->data->phpVersion->value.' + |
+
+ '.$php_sys->data->maxExecutionTime->name.' + |
+
+ '.$php_sys->data->maxExecutionTime->value.' + |
+
+ '.$php_sys->data->maxInputTime->name.' + |
+
+ '.$php_sys->data->maxInputTime->value.' + |
+
+ '.$php_sys->data->memoryLimit->name.' + |
+
+ '.$php_sys->data->memoryLimit->value.' + |
+
+ '.$php_sys->data->sessionLifetime->name.' + |
+
+ '.$php_sys->data->sessionLifetime->value.' + |
+