2013-04-05 Miguel de Dios <miguel.dedios@artica.es>
* mobile/operation/agents.php, mobile/operation/tactical.php, mobile/operation/home.php, mobile/include/style/main.css, include/functions_html.php, include/functions_reporting.php: some fixes and improves in the mobile console. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7936 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
a12dbe5a88
commit
3d65e51b0e
|
@ -1,3 +1,10 @@
|
||||||
|
2013-04-05 Miguel de Dios <miguel.dedios@artica.es>
|
||||||
|
|
||||||
|
* mobile/operation/agents.php, mobile/operation/tactical.php,
|
||||||
|
mobile/operation/home.php, mobile/include/style/main.css,
|
||||||
|
include/functions_html.php, include/functions_reporting.php: some
|
||||||
|
fixes and improves in the mobile console.
|
||||||
|
|
||||||
2013-04-05 Ramon Novoa <rnovoa@artica.es>
|
2013-04-05 Ramon Novoa <rnovoa@artica.es>
|
||||||
|
|
||||||
* include/functions_events.php: Display the event text properly.
|
* include/functions_events.php: Display the event text properly.
|
||||||
|
|
|
@ -14,6 +14,10 @@ body {
|
||||||
vertical-align: top;
|
vertical-align: top;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.small {
|
||||||
|
font-size: 10px !important;
|
||||||
|
}
|
||||||
|
|
||||||
.ui-header .ui-title {
|
.ui-header .ui-title {
|
||||||
font-size: 14px !important;
|
font-size: 14px !important;
|
||||||
}
|
}
|
||||||
|
@ -402,9 +406,9 @@ table#list_events th {
|
||||||
}
|
}
|
||||||
|
|
||||||
@media screen and (max-width: 35em) {
|
@media screen and (max-width: 35em) {
|
||||||
/* Put in new line the event name */
|
/* Hide the title of event name */
|
||||||
#list_events tbody tr.events td.cell_0 b.ui-table-cell-label {
|
#list_events tbody tr.events td.cell_0 b.ui-table-cell-label {
|
||||||
display: block;
|
display: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -432,7 +436,9 @@ table#list_events th {
|
||||||
#list_agents .cell_2 .ui-table-cell-label,
|
#list_agents .cell_2 .ui-table-cell-label,
|
||||||
#list_agents .cell_3 .ui-table-cell-label,
|
#list_agents .cell_3 .ui-table-cell-label,
|
||||||
#list_agents .cell_6 .ui-table-cell-label,
|
#list_agents .cell_6 .ui-table-cell-label,
|
||||||
#list_agents .cell_7 .ui-table-cell-label {
|
#list_agents .cell_4 .ui-table-cell-label,
|
||||||
|
#list_agents .cell_5 .ui-table-cell-label,
|
||||||
|
#list_agents .cell_8 .ui-table-cell-label {
|
||||||
min-width: auto !important;
|
min-width: auto !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -449,6 +455,25 @@ table#list_events th {
|
||||||
display: inline !important;
|
display: inline !important;
|
||||||
float: none !important;
|
float: none !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#list_agents .cell_4,
|
||||||
|
#list_agents .cell_8 {
|
||||||
|
display: inline !important;
|
||||||
|
float: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
#list_agents .cell_8 {
|
||||||
|
display: inline !important;
|
||||||
|
float: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
#list_agents b.ui-table-cell-label {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#list_agents .show_collapside {
|
||||||
|
display: inline !important;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
/*END-----------Agents styles-----------------------------------------*/
|
/*END-----------Agents styles-----------------------------------------*/
|
||||||
|
|
||||||
|
|
|
@ -253,14 +253,21 @@ class Agents {
|
||||||
$row = array();
|
$row = array();
|
||||||
|
|
||||||
$row[0] = $row[__('Agent')] = io_safe_output($agent['nombre']);
|
$row[0] = $row[__('Agent')] = io_safe_output($agent['nombre']);
|
||||||
$row[1] = $row[__('Description')] = ui_print_truncate_text($agent["description"], 'description', false, true);
|
$row[1] = $row[__('Description')] = '<span class="small">' .
|
||||||
|
ui_print_truncate_text($agent["description"], 'description', false, true) .
|
||||||
|
'</span>';
|
||||||
|
|
||||||
$row[2] = $row[__('OS')] = ui_print_os_icon ($agent["id_os"], false, true);
|
$row[2] = $row[__('OS')] = ui_print_os_icon ($agent["id_os"], false, true);
|
||||||
$row[3] = $row[__('Group')] = ui_print_group_icon ($agent["id_grupo"], true);
|
$row[3] = $row[__('Group')] = ui_print_group_icon ($agent["id_grupo"], true);
|
||||||
$row[4] = $row[__('Interval')] = human_time_description_raw($agent["intervalo"]);
|
$row[4] = $row[__('Interval')] = '<span class="show_collapside" style="vertical-align: 0%; display: none; font-weight: bolder;"> ' . __('I.') . ' </span>' .
|
||||||
$row[5] = $row[__('Modules')] = reporting_tiny_stats($agent, true);
|
'<span style="vertical-align: 0%;">' . human_time_description_raw($agent["intervalo"]) . '</span>';
|
||||||
$row[6] = $row[__('Status')] = agents_tree_view_status_img ($agent["critical_count"],
|
$row[5] = $row[__('Status')] = '<span class="show_collapside" style="vertical-align: 10%; display: none; font-weight: bolder;">' . __('S.') . ' </span>' . agents_tree_view_status_img ($agent["critical_count"],
|
||||||
$agent["warning_count"], $agent["unknown_count"]);
|
$agent["warning_count"], $agent["unknown_count"]);
|
||||||
$row[7] = $row[__('Alerts')] = agents_tree_view_alert_img ($agent["fired_count"]);
|
$row[6] = $row[__('Alerts')] = '<span class="show_collapside" style="vertical-align: 10%; display: none; font-weight: bolder;"> ' . __('A.') . ' </span>' . agents_tree_view_alert_img ($agent["fired_count"]);
|
||||||
|
|
||||||
|
$row[7] = $row[__('Modules')] = '<span class="show_collapside" style="vertical-align: 0%; display: none; font-weight: bolder;"> ' . __('M.') . ' </span>' .
|
||||||
|
reporting_tiny_stats($agent, true);
|
||||||
|
|
||||||
$last_time = strtotime ($agent["ultimo_contacto"]);
|
$last_time = strtotime ($agent["ultimo_contacto"]);
|
||||||
$now = time ();
|
$now = time ();
|
||||||
$diferencia = $now - $last_time;
|
$diferencia = $now - $last_time;
|
||||||
|
@ -271,6 +278,9 @@ class Agents {
|
||||||
else
|
else
|
||||||
$row[8] = $row[__('Last contact')] = $time;
|
$row[8] = $row[__('Last contact')] = $time;
|
||||||
|
|
||||||
|
$row[8] = $row[__('Last contact')] = '<span class="show_collapside" style="vertical-align: 0%; display: none; font-weight: bolder;"> ' . __('L.') . ' </span>' .
|
||||||
|
$row[__('Last contact')];
|
||||||
|
|
||||||
if (!$ajax) {
|
if (!$ajax) {
|
||||||
unset($row[0]);
|
unset($row[0]);
|
||||||
unset($row[1]);
|
unset($row[1]);
|
||||||
|
|
|
@ -127,6 +127,15 @@ class Events {
|
||||||
|
|
||||||
$event = events_get_event($id_event);
|
$event = events_get_event($id_event);
|
||||||
if ($event) {
|
if ($event) {
|
||||||
|
//Check if it is a event from module.
|
||||||
|
if ($event['id_agentmodule'] > 0) {
|
||||||
|
$event['module_graph_link'] =
|
||||||
|
'<a data-ajax="false" href="index.php?page=module_graph&id=' . $event['id_agentmodule'] . '">' .
|
||||||
|
html_print_image('images/chart_curve.png', true, array ("style" => 'vertical-align: middle;')) .
|
||||||
|
'</a>';
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
$event['evento'] = io_safe_output($event['evento']);
|
$event['evento'] = io_safe_output($event['evento']);
|
||||||
|
|
||||||
$event['clean_tags'] = events_clean_tags($event['tags']);
|
$event['clean_tags'] = events_clean_tags($event['tags']);
|
||||||
|
@ -361,33 +370,18 @@ class Events {
|
||||||
$options['title_close_button'] = true;
|
$options['title_close_button'] = true;
|
||||||
$options['title_text'] = __('Event detail');
|
$options['title_text'] = __('Event detail');
|
||||||
|
|
||||||
$table = new Table();
|
|
||||||
$table->row_keys_as_head_row = true;
|
|
||||||
$table->addRow(array('event_id' => ""), __('Event ID'));
|
|
||||||
$table->addRow(array('event_name' => ""), __('Event name'));
|
|
||||||
$table->addRow(array('event_timestamp' => ""), __('Timestamp'));
|
|
||||||
$table->addRow(array('event_owner' => ""), __('Owner'));
|
|
||||||
$table->addRow(array('event_type' => ""), __('Type'));
|
|
||||||
$table->addRow(array('event_repeated' => ""), __('Repeated'));
|
|
||||||
$table->addRow(array('event_severity' => ""), __('Severity'));
|
|
||||||
$table->addRow(array('event_status' => ""), __('Status'));
|
|
||||||
$table->addRow(array('event_acknowledged_by' => ""), __('Acknowledged by'));
|
|
||||||
$table->addRow(array('event_group' => ""), __('Group'));
|
|
||||||
$table->addRow(array('event_tags' => ""), __('Tags'));
|
|
||||||
|
|
||||||
//Content
|
//Content
|
||||||
ob_start();
|
ob_start();
|
||||||
?>
|
?>
|
||||||
<table class="pandora_responsive">
|
<table class="pandora_responsive">
|
||||||
<tbody>
|
<tbody>
|
||||||
|
<tr class="event_name">
|
||||||
|
<td class="cell_event_name" colspan="2"></td>
|
||||||
|
</tr>
|
||||||
<tr class="event_id">
|
<tr class="event_id">
|
||||||
<th><?php echo __('Event ID');?></th>
|
<th><?php echo __('Event ID');?></th>
|
||||||
<td class="cell_event_id"></td>
|
<td class="cell_event_id"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="event_name">
|
|
||||||
<th><?php echo __('Event name');?></th>
|
|
||||||
<td class="cell_event_name"></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="event_timestamp">
|
<tr class="event_timestamp">
|
||||||
<th><?php echo __('Timestamp');?></th>
|
<th><?php echo __('Timestamp');?></th>
|
||||||
<td class="cell_event_timestamp"></td>
|
<td class="cell_event_timestamp"></td>
|
||||||
|
@ -420,6 +414,11 @@ class Events {
|
||||||
<th><?php echo __('Group');?></th>
|
<th><?php echo __('Group');?></th>
|
||||||
<td class="cell_event_group"></td>
|
<td class="cell_event_group"></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
</tr>
|
||||||
|
<tr class="event_module_graph">
|
||||||
|
<th><?php echo __('Module Graph');?></th>
|
||||||
|
<td class="cell_module_graph"></td>
|
||||||
|
</tr>
|
||||||
<tr class="event_tags">
|
<tr class="event_tags">
|
||||||
<th><?php echo __('Tags');?></th>
|
<th><?php echo __('Tags');?></th>
|
||||||
<td class="cell_event_tags"></td>
|
<td class="cell_event_tags"></td>
|
||||||
|
@ -778,6 +777,13 @@ class Events {
|
||||||
$(\"#detail_event_dialog .cell_event_tags\")
|
$(\"#detail_event_dialog .cell_event_tags\")
|
||||||
.html(event[\"tags\"]);
|
.html(event[\"tags\"]);
|
||||||
|
|
||||||
|
//The link to module graph
|
||||||
|
$(\".event_module_graph\").hide();
|
||||||
|
if (event[\"id_agentmodule\"] != \"0\") {
|
||||||
|
$(\".event_module_graph\").show();
|
||||||
|
$(\".cell_module_graph\").html(event[\"module_graph_link\"]);
|
||||||
|
}
|
||||||
|
|
||||||
$(\"#event_id\").val(id_event);
|
$(\"#event_id\").val(id_event);
|
||||||
|
|
||||||
if (event[\"estado\"] != 1) {
|
if (event[\"estado\"] != 1) {
|
||||||
|
|
Loading…
Reference in New Issue