mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-31 01:35:36 +02:00
2013-01-15 Sergio Martin <sergio.martin@artica.es>
* include/functions.php include/constants.php operation/events/events_list.php: Added two new criticity modes in the event filter. Critical or warning and not normal * operation/menu.php: Delete the metaconsole menu enterprise call from operation menu git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7473 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
8a4793e0a8
commit
065d06e80d
@ -1,3 +1,14 @@
|
|||||||
|
2013-01-15 Sergio Martin <sergio.martin@artica.es>
|
||||||
|
|
||||||
|
* include/functions.php
|
||||||
|
include/constants.php
|
||||||
|
operation/events/events_list.php: Added two new
|
||||||
|
criticity modes in the event filter. Critical or warning
|
||||||
|
and not normal
|
||||||
|
|
||||||
|
* operation/menu.php: Delete the metaconsole menu enterprise call
|
||||||
|
from operation menu
|
||||||
|
|
||||||
2013-01-15 Dario Rodriguez <dario.rodriguez@artica.es>
|
2013-01-15 Dario Rodriguez <dario.rodriguez@artica.es>
|
||||||
|
|
||||||
* include/functions_visual_map.php: Now modules with warning
|
* include/functions_visual_map.php: Now modules with warning
|
||||||
|
@ -207,4 +207,16 @@ define ('STATUS_ALERT_DISABLED', 'alert_disabled.png');
|
|||||||
//For servers
|
//For servers
|
||||||
define ('STATUS_SERVER_OK', 'server_ok.png');
|
define ('STATUS_SERVER_OK', 'server_ok.png');
|
||||||
define ('STATUS_SERVER_DOWN', 'server_down.png');
|
define ('STATUS_SERVER_DOWN', 'server_down.png');
|
||||||
|
|
||||||
|
/* Events criticity */
|
||||||
|
define ('EVENT_CRIT_MAINTENANCE', 0);
|
||||||
|
define ('EVENT_CRIT_INFORMATIONAL', 1);
|
||||||
|
define ('EVENT_CRIT_NORMAL', 2);
|
||||||
|
define ('EVENT_CRIT_MINOR', 5);
|
||||||
|
define ('EVENT_CRIT_WARNING', 3);
|
||||||
|
define ('EVENT_CRIT_MAJOR', 6);
|
||||||
|
define ('EVENT_CRIT_CRITICAL', 4);
|
||||||
|
define ('EVENT_CRIT_WARNING_OR_CRITICAL', 34);
|
||||||
|
define ('EVENT_CRIT_NOT_NORMAL', 20);
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
@ -900,13 +900,15 @@ function get_priorities () {
|
|||||||
global $config;
|
global $config;
|
||||||
|
|
||||||
$priorities = array ();
|
$priorities = array ();
|
||||||
$priorities[0] = __('Maintenance');
|
$priorities[EVENT_CRIT_MAINTENANCE] = __('Maintenance');
|
||||||
$priorities[1] = __('Informational');
|
$priorities[EVENT_CRIT_INFORMATIONAL] = __('Informational');
|
||||||
$priorities[2] = __('Normal');
|
$priorities[EVENT_CRIT_NORMAL] = __('Normal');
|
||||||
$priorities[5] = __('Minor');
|
$priorities[EVENT_CRIT_MINOR] = __('Minor');
|
||||||
$priorities[3] = __('Warning');
|
$priorities[EVENT_CRIT_WARNING] = __('Warning');
|
||||||
$priorities[6] = __('Major');
|
$priorities[EVENT_CRIT_MAJOR] = __('Major');
|
||||||
$priorities[4] = __('Critical');
|
$priorities[EVENT_CRIT_CRITICAL] = __('Critical');
|
||||||
|
$priorities[EVENT_CRIT_WARNING_OR_CRITICAL] = __('Warning').'/'.__('Critical');
|
||||||
|
$priorities[EVENT_CRIT_NOT_NORMAL] = __('Not normal');
|
||||||
|
|
||||||
foreach ($priorities as $key => $priority) {
|
foreach ($priorities as $key => $priority) {
|
||||||
$priorities[$key] = ui_print_truncate_text($priority, GENERIC_SIZE_TEXT, false, true, false);
|
$priorities[$key] = ui_print_truncate_text($priority, GENERIC_SIZE_TEXT, false, true, false);
|
||||||
|
@ -209,8 +209,20 @@ if ($event_type != "") {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if ($severity != -1)
|
if ($severity != -1) {
|
||||||
$sql_post .= " AND criticity = " . $severity;
|
switch($severity) {
|
||||||
|
case EVENT_CRIT_WARNING_OR_CRITICAL:
|
||||||
|
$sql_post .= " AND (criticity = " . EVENT_CRIT_WARNING . " OR
|
||||||
|
criticity = " . EVENT_CRIT_CRITICAL . ")";
|
||||||
|
break;
|
||||||
|
case EVENT_CRIT_NOT_NORMAL:
|
||||||
|
$sql_post .= " AND criticity != " . EVENT_CRIT_NORMAL;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
$sql_post .= " AND criticity = $severity";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// In metaconsole mode the agent search is performed by name
|
// In metaconsole mode the agent search is performed by name
|
||||||
if($meta) {
|
if($meta) {
|
||||||
@ -351,7 +363,7 @@ echo "</td></tr><tr>";
|
|||||||
|
|
||||||
// Severity
|
// Severity
|
||||||
echo "<td>".__('Severity')."</td><td>";
|
echo "<td>".__('Severity')."</td><td>";
|
||||||
html_print_select (get_priorities (), "severity", $severity, '', __('All'), '-1');
|
html_print_select (get_priorities (), "severity", $severity, '', __('All'), '-1', false, false, false);
|
||||||
echo '</td>';
|
echo '</td>';
|
||||||
|
|
||||||
// Status
|
// Status
|
||||||
|
@ -26,10 +26,7 @@ $menu_operation = array ();
|
|||||||
$menu_operation['class'] = 'operation';
|
$menu_operation['class'] = 'operation';
|
||||||
|
|
||||||
// Agent read, Server read
|
// Agent read, Server read
|
||||||
if (check_acl ($config['id_user'], 0, "AR")) {
|
if (check_acl ($config['id_user'], 0, "AR")) {
|
||||||
|
|
||||||
enterprise_hook ('metaconsole_menu');
|
|
||||||
|
|
||||||
//View agents
|
//View agents
|
||||||
$menu_operation["estado"]["text"] = __('Monitoring');
|
$menu_operation["estado"]["text"] = __('Monitoring');
|
||||||
$menu_operation["estado"]["sec2"] = "operation/agentes/tactical";
|
$menu_operation["estado"]["sec2"] = "operation/agentes/tactical";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user