mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-31 01:35:36 +02:00
2013-03-08 Sergio Martin <sergio.martin@artica.es>
* include/ajax/events.php include/graphs/flot/pandora.flot.js: Improve the view of events information in flot graphs for bug 3607101 * godmode/agentes/module_manager_editor_network.php godmode/modules/manage_network_components_form.php godmode/modules/manage_network_components_form_network.php: Fix some bugs of module templates application and snmp modules edition git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7815 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
05f3f7872c
commit
dc057a2dbb
@ -1,3 +1,14 @@
|
|||||||
|
2013-03-08 Sergio Martin <sergio.martin@artica.es>
|
||||||
|
|
||||||
|
* include/ajax/events.php
|
||||||
|
include/graphs/flot/pandora.flot.js: Improve the view
|
||||||
|
of events information in flot graphs for bug 3607101
|
||||||
|
|
||||||
|
* godmode/agentes/module_manager_editor_network.php
|
||||||
|
godmode/modules/manage_network_components_form.php
|
||||||
|
godmode/modules/manage_network_components_form_network.php: Fix
|
||||||
|
some bugs of module templates application and snmp modules edition
|
||||||
|
|
||||||
2013-03-07 Mario Pulido <mario.pulido@artica.es>
|
2013-03-07 Mario Pulido <mario.pulido@artica.es>
|
||||||
|
|
||||||
*images/help/historyddbb.png,images/help/plugin1.png
|
*images/help/historyddbb.png,images/help/plugin1.png
|
||||||
|
@ -80,7 +80,7 @@ else {
|
|||||||
$data[2] = _('SNMP version');
|
$data[2] = _('SNMP version');
|
||||||
|
|
||||||
if ($id_module_type >= 15 && $id_module_type <= 18) {
|
if ($id_module_type >= 15 && $id_module_type <= 18) {
|
||||||
$data[3] = html_print_select ($snmp_versions, 'snmp_version', $snmp_version,
|
$data[3] = html_print_select ($snmp_versions, 'snmp_version', $tcp_send,
|
||||||
'', '', '', true, false, false, '', $disabledBecauseInPolicy);
|
'', '', '', true, false, false, '', $disabledBecauseInPolicy);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -35,6 +35,7 @@ if ($create_network_from_module) {
|
|||||||
|
|
||||||
$name = $data_module["nombre"];
|
$name = $data_module["nombre"];
|
||||||
$description = $data_module["descripcion"];
|
$description = $data_module["descripcion"];
|
||||||
|
$type = $data_module["id_tipo_modulo"];
|
||||||
$max = $data_module["max"];
|
$max = $data_module["max"];
|
||||||
$min = $data_module["min"];
|
$min = $data_module["min"];
|
||||||
$module_interval = $data_module["module_interval"];
|
$module_interval = $data_module["module_interval"];
|
||||||
|
@ -25,12 +25,10 @@ if (! check_acl ($config['id_user'], 0, "PM")) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! $id) {
|
if (!$id && !isset($snmp_community)) {
|
||||||
$snmp_community = "public";
|
$snmp_community = "public";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$snmp_versions['1'] = 'v. 1';
|
$snmp_versions['1'] = 'v. 1';
|
||||||
$snmp_versions['2'] = 'v. 2';
|
$snmp_versions['2'] = 'v. 2';
|
||||||
$snmp_versions['2c'] = 'v. 2c';
|
$snmp_versions['2c'] = 'v. 2c';
|
||||||
|
@ -401,24 +401,53 @@ if ($get_events_details) {
|
|||||||
foreach($events as $event) {
|
foreach($events as $event) {
|
||||||
switch($event["estado"]) {
|
switch($event["estado"]) {
|
||||||
case 0:
|
case 0:
|
||||||
$img = "../../images/star.png";
|
$img = ui_get_full_url("images/star.png", false, false, false);
|
||||||
$title = __('New event');
|
$title = __('New event');
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
$img = "../../images/tick.png";
|
$img = ui_get_full_url("images/tick.png", false, false, false);
|
||||||
$title = __('Event validated');
|
$title = __('Event validated');
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
$img = "../../images/hourglass.png";
|
$img = ui_get_full_url("images/hourglass.png", false, false, false);
|
||||||
$title = __('Event in process');
|
$title = __('Event in process');
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
$out .= '<tr class="'.get_priority_class ($event['criticity']).'"><td class="'.get_priority_class ($event['criticity']).'">';
|
$out .= '<tr class="'.get_priority_class ($event['criticity']).'" style="height: 25px;">';
|
||||||
$out .= '<img src="'.$img.'" alt="'.$title.'" title="'.$title.'">';
|
$out .= '<td class="'.get_priority_class ($event['criticity']).'" style="font-size:7pt" colspan=2>';
|
||||||
$out .= '</td><td class="'.get_priority_class ($event['criticity']).'" style="font-size:7pt">';
|
|
||||||
$out .= io_safe_output($event['evento']);
|
$out .= io_safe_output($event['evento']);
|
||||||
$out .= '</td></tr><tr style="font-size:0px; heigth: 0px; background: #999;"><td></td><td>';
|
$out .= '</td></tr>';
|
||||||
|
|
||||||
|
$out .= '<tr class="'.get_priority_class ($event['criticity']).'" style="font-size:0px; height: 25px;">';
|
||||||
|
$out .= '<td class="'.get_priority_class ($event['criticity']).'" style="width: 18px; text-align:center;">';
|
||||||
|
$out .= html_print_image(ui_get_full_url('images/clock.png', false, false, false), true, array('title' => __('Timestamp')), false, true);
|
||||||
|
|
||||||
|
$out .= '</td>';
|
||||||
|
$out .= '<td class="'.get_priority_class ($event['criticity']).'" style="font-size:7pt">';
|
||||||
|
$out .= date($config['date_format'], $event['utimestamp']);
|
||||||
|
$out .= '</td></tr>';
|
||||||
|
|
||||||
|
$out .= '<tr class="'.get_priority_class ($event['criticity']).'" style="font-size:0px; height: 25px;">';
|
||||||
|
$out .= '<td class="'.get_priority_class ($event['criticity']).'" style="width: 18px; text-align:center;">';
|
||||||
|
$out .= html_print_image($img, true, array('title' => $title), false, true);
|
||||||
|
$out .= '</td>';
|
||||||
|
$out .= '<td class="'.get_priority_class ($event['criticity']).'" style="font-size:7pt">';
|
||||||
|
$out .= $title;
|
||||||
|
if($event["estado"] == 1) {
|
||||||
|
if(empty($event['id_usuario'])) {
|
||||||
|
$ack_user = '<i>' . __('Auto') . '</i>';
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$ack_user = $event['id_usuario'];
|
||||||
|
}
|
||||||
|
|
||||||
|
$out .= ' (' . $ack_user . ')';
|
||||||
|
}
|
||||||
|
|
||||||
|
$out .= '</td></tr>';
|
||||||
|
|
||||||
|
$out .= '<tr style="font-size:0px; heigth: 0px; background: #999;"><td></td><td>';
|
||||||
$out .= '</td></tr><tr style="font-size:0px; heigth: 0px; background: #ccc;"><td></td><td>';
|
$out .= '</td></tr><tr style="font-size:0px; heigth: 0px; background: #ccc;"><td></td><td>';
|
||||||
$out .= '</td></tr>';
|
$out .= '</td></tr>';
|
||||||
}
|
}
|
||||||
|
@ -852,12 +852,20 @@ function pandoraFlotArea(graph_id, values, labels, labels_long, legend, colors,
|
|||||||
switch(item.series.label) {
|
switch(item.series.label) {
|
||||||
case legend_alerts+series_suffix_str:
|
case legend_alerts+series_suffix_str:
|
||||||
case legend_alerts:
|
case legend_alerts:
|
||||||
extra_info = '<b>'+legend_alerts+' - '+labels_long[item.dataIndex]+'</b>'+get_event_details(alertsz[item.dataIndex]);
|
extra_info = '<b>'+legend_alerts+':<br><span style="font-size:xx-small; font-weight: normal;">From: '+labels_long[item.dataIndex];
|
||||||
|
if(labels_long[item.dataIndex+1] != undefined) {
|
||||||
|
extra_info += '<br>To: '+labels_long[item.dataIndex+1];
|
||||||
|
}
|
||||||
|
extra_info += '</span></b>'+get_event_details(alertsz[item.dataIndex]);
|
||||||
extra_show = true;
|
extra_show = true;
|
||||||
break;
|
break;
|
||||||
case legend_events+series_suffix_str:
|
case legend_events+series_suffix_str:
|
||||||
case legend_events:
|
case legend_events:
|
||||||
extra_info = '<b>'+legend_events+' - '+labels_long[item.dataIndex]+'</b>'+get_event_details(eventsz[item.dataIndex]);
|
extra_info = '<b>'+legend_events+':<br><span style="font-size:xx-small; font-weight: normal;">From: '+labels_long[item.dataIndex];
|
||||||
|
if(labels_long[item.dataIndex+1] != undefined) {
|
||||||
|
extra_info += '<br>To: '+labels_long[item.dataIndex+1];
|
||||||
|
}
|
||||||
|
extra_info += '</span></b>'+get_event_details(eventsz[item.dataIndex]);
|
||||||
extra_show = true;
|
extra_show = true;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@ -1055,6 +1063,7 @@ function get_event_details (event_ids) {
|
|||||||
async: false,
|
async: false,
|
||||||
success: function (data) {
|
success: function (data) {
|
||||||
table = data;
|
table = data;
|
||||||
|
//forced_title_callback();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user