2012-06-07 Juan Manuel Ramon <juanmanuel.ramon@artica.es>
* godmode/menu.php: Hide not valid sections with metaconsole activated. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6444 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
005a738ee3
commit
7d3dc49d64
|
@ -1,3 +1,8 @@
|
|||
2012-06-07 Juan Manuel Ramon <juanmanuel.ramon@artica.es>
|
||||
|
||||
* godmode/menu.php: Hide not valid sections with metaconsole
|
||||
activated.
|
||||
|
||||
2012-06-07 Juan Manuel Ramon <juanmanuel.ramon@artica.es>
|
||||
|
||||
* include/styles/pandora_minimal.css
|
||||
|
|
|
@ -24,7 +24,7 @@ require_once ('include/functions_menu.php');
|
|||
$menu = array ();
|
||||
$menu['class'] = 'godmode';
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "AW")) {
|
||||
if (check_acl ($config['id_user'], 0, "AW") and ($config['metaconsole'] == 0)) {
|
||||
$menu["gagente"]["text"] = __('Manage monitoring');
|
||||
$menu["gagente"]["sec2"] = "godmode/agentes/modificar_agente";
|
||||
$menu["gagente"]["id"] = "god-agents";
|
||||
|
@ -47,7 +47,7 @@ if (check_acl ($config['id_user'], 0, "AW")) {
|
|||
$menu["gagente"]["sub"] = $sub;
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "AW")) {
|
||||
if (check_acl ($config['id_user'], 0, "AW") and ($config['metaconsole'] == 0)) {
|
||||
$menu["gmassive"]["text"] = __('Massive operations');
|
||||
$menu["gmassive"]["sec2"] = "godmode/massive/massive_operations";
|
||||
$menu["gmassive"]["id"] = "god-massive";
|
||||
|
@ -70,7 +70,7 @@ if (check_acl ($config['id_user'], 0, "AW")) {
|
|||
}
|
||||
*/
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "PM")) {
|
||||
if (check_acl ($config['id_user'], 0, "PM") and ($config['metaconsole'] == 0)) {
|
||||
$menu["gmodules"]["text"] = __('Manage modules');
|
||||
$menu["gmodules"]["sec2"] = "godmode/modules/manage_network_templates";
|
||||
$menu["gmodules"]["id"] = "god-modules";
|
||||
|
@ -91,7 +91,7 @@ if (check_acl ($config['id_user'], 0, "PM")) {
|
|||
$menu["gmodules"]["sub"] = $sub;
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "LM")) {
|
||||
if (check_acl ($config['id_user'], 0, "LM") and ($config['metaconsole'] == 0)) {
|
||||
$menu["galertas"]["text"] = __('Manage alerts');
|
||||
$menu["galertas"]["sec2"] = "godmode/alerts/alert_list";
|
||||
$menu["galertas"]["id"] = "god-alerts";
|
||||
|
@ -110,11 +110,11 @@ if (check_acl ($config['id_user'], 0, "LM")) {
|
|||
$menu["galertas"]["sub"] = $sub;
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "AW")) {
|
||||
if (check_acl ($config['id_user'], 0, "AW") and ($config['metaconsole'] == 0)) {
|
||||
enterprise_hook ('policies_menu');
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "UM")) {
|
||||
if (check_acl ($config['id_user'], 0, "UM") and ($config['metaconsole'] == 0)) {
|
||||
$menu["gusuarios"]["text"] = __('Manage users');
|
||||
$menu["gusuarios"]["sec2"] = "godmode/users/user_list";
|
||||
$menu["gusuarios"]["id"] = "god-users";
|
||||
|
@ -126,7 +126,7 @@ if (check_acl ($config['id_user'], 0, "UM")) {
|
|||
}
|
||||
|
||||
// GIS
|
||||
if (check_acl ($config['id_user'], 0, "IW")) {
|
||||
if (check_acl ($config['id_user'], 0, "IW") and ($config['metaconsole'] == 0)) {
|
||||
|
||||
if ($config['activate_gis']) {
|
||||
$menu["godgismaps"]["text"] = __('GIS Maps builder');
|
||||
|
@ -141,7 +141,7 @@ if (check_acl ($config['id_user'], 0, "IW")) {
|
|||
}
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "IW")) {
|
||||
if (check_acl ($config['id_user'], 0, "IW") and ($config['metaconsole'] == 0)) {
|
||||
// Manage events
|
||||
$menu["geventos"]["text"] = __('Manage events');
|
||||
$menu["geventos"]["sec2"] = "godmode/events/events&section=filter";
|
||||
|
@ -154,7 +154,7 @@ if (check_acl ($config['id_user'], 0, "IW")) {
|
|||
$menu["geventos"]["sub"] = $sub;
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "AW")) {
|
||||
if (check_acl ($config['id_user'], 0, "AW") and ($config['metaconsole'] == 0)) {
|
||||
|
||||
// Servers
|
||||
$menu["gservers"]["text"] = __('Manage servers');
|
||||
|
@ -176,7 +176,7 @@ if (check_acl ($config['id_user'], 0, "AW")) {
|
|||
$menu["gservers"]["sub"] = $sub;
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "LW")) {
|
||||
if (check_acl ($config['id_user'], 0, "LW") and ($config['metaconsole'] == 0)) {
|
||||
enterprise_hook ('snmpconsole_menu');
|
||||
}
|
||||
|
||||
|
@ -212,7 +212,7 @@ if (check_acl ($config['id_user'], 0, "PM")) {
|
|||
$menu["gsetup"]["sub"] = $sub;
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "AW")) {
|
||||
if (check_acl ($config['id_user'], 0, "AW") and ($config['metaconsole'] == 0)) {
|
||||
if ($config['activate_netflow']) {
|
||||
//Netflow
|
||||
$menu["netf"]["text"] = __('Netflow');
|
||||
|
@ -227,7 +227,7 @@ if (check_acl ($config['id_user'], 0, "AW")) {
|
|||
}
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], 0, "DM")) {
|
||||
if (check_acl ($config['id_user'], 0, "DM") and ($config['metaconsole'] == 0)) {
|
||||
$menu["gdbman"]["text"] = __('DB maintenance');
|
||||
$menu["gdbman"]["sec2"] = "godmode/db/db_main";
|
||||
$menu["gdbman"]["id"] = "god-dbmaint";
|
||||
|
@ -270,7 +270,8 @@ if (check_acl ($config['id_user'], 0, "PM")) {
|
|||
} else {
|
||||
|
||||
if (array_key_exists('fatherId',$extmenu)) {
|
||||
if (strlen($extmenu['fatherId']) > 0) {
|
||||
// Check that extension father ID exists previously on the menu (only if metaconsole is activated)
|
||||
if (strlen($extmenu['fatherId']) > 0 and (($config['metaconsole'] == 0) or (array_key_exists($extension_menu['fatherId'], $menu)))) {
|
||||
$menu[$extmenu['fatherId']]['sub'][$extmenu['sec2']]["text"] = __($extmenu['name']);
|
||||
if ($extmenu["name"] != 'DB interface'){
|
||||
if (!empty($config['refr'])){
|
||||
|
|
Loading…
Reference in New Issue