diff --git a/pandora_console/include/ajax/alert_list.ajax.php b/pandora_console/include/ajax/alert_list.ajax.php index 7d9e372d7e..46792c7822 100644 --- a/pandora_console/include/ajax/alert_list.ajax.php +++ b/pandora_console/include/ajax/alert_list.ajax.php @@ -639,6 +639,7 @@ if ($alert_validate === true) { } if ($get_agent_alerts_datatable === true) { + hd('holaaaaaaaaaaaaaa', true); // Datatables offset, limit and order. $filter_alert = get_parameter('filter', []); unset($filter_alert[0]); diff --git a/pandora_console/operation/agentes/alerts_status.php b/pandora_console/operation/agentes/alerts_status.php index a7c8cd56b7..418e52e8a8 100755 --- a/pandora_console/operation/agentes/alerts_status.php +++ b/pandora_console/operation/agentes/alerts_status.php @@ -222,70 +222,70 @@ if (empty($free_search) === false) { $columns = []; $column_names = []; -if (is_metaconsole() === false) { - if ((bool) check_acl($config['id_user'], $id_group, 'LW') === true || (bool) check_acl($config['id_user'], $id_group, 'LM') === true) { + +if ((bool) check_acl($config['id_user'], $id_group, 'LW') === true || (bool) check_acl($config['id_user'], $id_group, 'LM') === true) { + array_unshift( + $column_names, + [ + 'title' => __('Standby'), + 'text' => __('Standby'), + ], + ); + + $columns = array_merge( + ['standby'], + $columns + ); + + if ($isFunctionPolicies !== ENTERPRISE_NOT_HOOK) { array_unshift( $column_names, [ - 'title' => __('Standby'), - 'text' => __('Standby'), - ], + 'title' => __('Policy'), + 'text' => __('Policy'), + ] ); $columns = array_merge( - ['standby'], + ['policy'], $columns ); - - if ($isFunctionPolicies !== ENTERPRISE_NOT_HOOK) { - array_unshift( - $column_names, - [ - 'title' => __('Policy'), - 'text' => __('Policy'), - ] - ); - - $columns = array_merge( - ['policy'], - $columns - ); - } - - if ($print_agent === true) { - array_push( - $column_names, - ['text' => 'Agent'] - ); - - $columns = array_merge( - $columns, - ['agent_name'] - ); - } } - if ((bool) check_acl($config['id_user'], $id_group, 'AW') === true || (bool) check_acl($config['id_user'], $id_group, 'LM') === true) { + if ($print_agent === true) { array_push( $column_names, - ['text' => 'Module'], - ['text' => 'Template'], - ['text' => 'Operation'], - ['text' => 'Last fired'], - ['text' => 'Status'] + ['text' => 'Agent'] ); $columns = array_merge( $columns, - ['agent_module_name'], - ['template_name'], - ['operation'], - ['last_fired'], - ['status'] + ['agent_name'] ); } } +if ((bool) check_acl($config['id_user'], $id_group, 'AW') === true || (bool) check_acl($config['id_user'], $id_group, 'LM') === true) { + array_push( + $column_names, + ['text' => 'Module'], + ['text' => 'Template'], + ['text' => 'Operation'], + ['text' => 'Last fired'], + ['text' => 'Status'] + ); + + $columns = array_merge( + $columns, + ['agent_module_name'], + ['template_name'], + ['operation'], + ['last_fired'], + ['status'] + ); +} + + if ($print_agent === true) { array_push( $column_names, @@ -450,7 +450,7 @@ if ($agent_view_page === true) { ); } -if ((is_metaconsole() === false) && ((bool) check_acl($config['id_user'], $id_group, 'AW') === true || (bool) check_acl($config['id_user'], $id_group, 'LM') === true)) { +if (((bool) check_acl($config['id_user'], $id_group, 'AW') === true || (bool) check_acl($config['id_user'], $id_group, 'LM') === true)) { if ($agent_view_page === true) { html_print_div( [ diff --git a/pandora_console/operation/agentes/status_monitor.php b/pandora_console/operation/agentes/status_monitor.php index de78a3b331..f431ecdf9c 100644 --- a/pandora_console/operation/agentes/status_monitor.php +++ b/pandora_console/operation/agentes/status_monitor.php @@ -1388,7 +1388,7 @@ if ($autosearch) { } if ($count_modules > $config['block_size']) { - $tablePagination = ui_pagination($count_modules, false, $offset, 0, true); + $tablePagination = ui_pagination($count_modules, false, $offset, 0, true, 'offset', false); } // Get number of elements of the pagination.