diff --git a/pandora_console/include/functions_events.php b/pandora_console/include/functions_events.php index e2ab0987df..26ded59964 100644 --- a/pandora_console/include/functions_events.php +++ b/pandora_console/include/functions_events.php @@ -2962,7 +2962,7 @@ function events_get_events_grouped_by_agent($sql_post, $offset = 0, $table = events_get_events_table($meta, $history); if ($meta) { - $fields_extra = ', agent_name'; + $fields_extra = ', agent_name, server_id'; $groupby_extra = ', server_id'; } else { @@ -3022,7 +3022,7 @@ function events_get_events_grouped_by_agent($sql_post, $offset = 0, $id_agente = $event['agent_name']; $result[] = array('total' => $event['total'], - 'id_server' => $event['id_server'], + 'id_server' => $event['server_id'], 'id_agent' => $id_agente, 'event_type' => $resultado['event_type']); } diff --git a/pandora_console/include/javascript/pandora_events.js b/pandora_console/include/javascript/pandora_events.js index 84b2f01966..31b1e01028 100644 --- a/pandora_console/include/javascript/pandora_events.js +++ b/pandora_console/include/javascript/pandora_events.js @@ -491,8 +491,9 @@ function event_comment() { //Show event list when fielter repetead is Group agents function show_events_group_agent (id_insert, id_agent, server_id) { - parameter = []; + var ajax_file = $('#hidden-ajax_file').val(); + parameter = []; parameter.push ({name: "id_agent", value: id_agent}); parameter.push ({name: "server_id", @@ -522,7 +523,7 @@ function show_events_group_agent (id_insert, id_agent, server_id) { parameter.push ({name: "date_to", value: $("#text-date_to").val()}); parameter.push ({name: "server_id_search", - value: $("#text-date_to").val()}); + value: $("#server_id").val()}); parameter.push ({ name: "page", value: "include/ajax/events"}); @@ -532,7 +533,7 @@ function show_events_group_agent (id_insert, id_agent, server_id) { jQuery.ajax ({ type: 'POST', - url: 'ajax.php', + url: action=ajax_file, data: parameter, dataType: 'html', success: function (data) { diff --git a/pandora_console/include/styles/pandora.css b/pandora_console/include/styles/pandora.css index b5f358bddb..c1d9caf8db 100644 --- a/pandora_console/include/styles/pandora.css +++ b/pandora_console/include/styles/pandora.css @@ -3315,3 +3315,8 @@ div#vc-controls img.vc-qr { display: none; } /* jQuery dialog */ + +/* Image open dialog in group events by agents*/ +#open_agent_groups { + cursor: pointer; +} \ No newline at end of file diff --git a/pandora_console/operation/events/events.build_table.php b/pandora_console/operation/events/events.build_table.php index e27ecda54a..145118f8ee 100644 --- a/pandora_console/operation/events/events.build_table.php +++ b/pandora_console/operation/events/events.build_table.php @@ -93,7 +93,7 @@ if ($group_rep == 2) { $uniq = uniqid(); if ($meta) { $table->data[$key][2] = ''; + onclick=\'show_events_group_agent("'.$table->id.'-'.$uniq.'-0","'.$res['id_agent'].'",'.$res['id_server'].');\' />'; } else { $table->data[$key][2] = '