From c7e410b16daff3720d9fab29477c952a4d3abef6 Mon Sep 17 00:00:00 2001 From: Tatiana Llorente Date: Wed, 3 Jul 2019 11:08:17 +0200 Subject: [PATCH] Added discovery submenus to main menu - #4203 --- pandora_console/godmode/menu.php | 20 +++++++++++++++++--- pandora_console/include/functions_menu.php | 3 +++ 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/pandora_console/godmode/menu.php b/pandora_console/godmode/menu.php index 14caf1b9cb..09a2aff770 100644 --- a/pandora_console/godmode/menu.php +++ b/pandora_console/godmode/menu.php @@ -24,9 +24,23 @@ $menu_godmode['class'] = 'godmode'; if (check_acl($config['id_user'], 0, 'PM')) { $sub = []; - $sub['godmode/servers/discovery']['text'] = __('Discovery'); - $sub['godmode/servers/discovery']['id'] = 'Discovery'; - $sub['godmode/servers/discovery']['subsecs'] = ['godmode/servers/discovery']; + $sub['godmode/servers/discovery&wiz=main']['text'] = __('Discovery Main'); + $sub['godmode/servers/discovery&wiz=main']['id'] = 'Discovery'; + + $sub['godmode/servers/discovery&wiz=tasklist']['text'] = __('Task list'); + $sub['godmode/servers/discovery&wiz=tasklist']['id'] = 'tasklist'; + + $sub['godmode/servers/discovery&wiz=app']['text'] = __('Applications'); + $sub['godmode/servers/discovery&wiz=app']['id'] = 'app'; + + $sub['godmode/servers/discovery&wiz=cloud']['text'] = __('Cloud'); + $sub['godmode/servers/discovery&wiz=cloud']['id'] = 'cloud'; + + $sub['godmode/servers/discovery&wiz=ctask']['text'] = __('Console task'); + $sub['godmode/servers/discovery&wiz=ctask']['id'] = 'ctask'; + + $sub['godmode/servers/discovery&wiz=hd']['text'] = __('Host & devices'); + $sub['godmode/servers/discovery&wiz=hd']['id'] = 'hd'; // Add to menu. $menu_godmode['discovery']['text'] = __('Discovery'); diff --git a/pandora_console/include/functions_menu.php b/pandora_console/include/functions_menu.php index 3f8a8cd33b..98191d231f 100644 --- a/pandora_console/include/functions_menu.php +++ b/pandora_console/include/functions_menu.php @@ -52,6 +52,9 @@ function menu_print_menu(&$menu) $sec2 = (string) get_parameter('sec2'); if ($sec2 == 'operation/agentes/ver_agente') { $sec2 = 'godmode/agentes/configurar_agente'; + } else if ($sec2 == 'godmode/servers/discovery') { + $wiz = (string) get_parameter('wiz'); + $sec2 = 'godmode/servers/discovery&wiz='.$wiz; } else { $sec2 = (string) get_parameter('sec2'); }