';
}
else {
echo '
';
}
// Agent select
$table->data[0][0] = ''.__('Agent').'';
$table->data[0][1] = print_select ($agents, 'filter_agent', $filter_agent, 'javascript:this.form.submit();', __('All'), '', true);
// OID select
$table->data[0][2] = ''.__('OID').'';
$table->data[0][3] = print_select ($oids, 'filter_oid', $filter_oid, 'javascript:this.form.submit();', __('All'), '', true);
// Alert status select
$table->data[1][0] = ''.__('Alert').'';
$table->data[1][1] = print_select ($alerted, "filter_fired", $filter_fired, 'javascript:this.form.submit();', __('All'), '-1', true);
// String search_string
$table->data[1][2] = ''.__('Search value').'';
$table->data[1][3] = print_input_text ('search_string', $search_string, '', 25, 0, true);
// Block size for pagination select
$table->data[2][0] = ''.__('Block size for pagination').'';
$paginations[25] = 25;
$paginations[50] = 50;
$paginations[100] = 100;
$paginations[200] = 200;
$paginations[500] = 500;
$table->data[2][1] = print_select ($paginations, "pagination", $pagination, 'this.form.submit();', __('Default'), $config["block_size"], true);
// Severity select
$table->data[2][2] = ''.__('Severity').'';
$table->data[2][3] = print_select ($severities, 'filter_severity', $filter_severity, 'this.form.submit();', __('All'), -1, true);
// Status
$table->data[3][0] = ''.__('Status').'';
$status[-1] = __('All');
$status[0] = __('Not validated');
$status[1] = __('Validated');
$table->data[3][1] = print_select ($status, 'filter_status', $filter_status, 'this.form.submit();', '', '', true);
print_table ($table);
unset ($table);
echo '';
echo '
';
echo '
';
// Prepare index for pagination
$trapcount = get_db_sql ("SELECT COUNT(*) FROM ttrap " . $whereSubquery);
$urlPagination = "index.php?sec=snmpconsole&sec2=operation/snmpconsole/snmp_view&filter_agent=" . $filter_agent
. "&filter_oid=" . $filter_oid . "&filter_severity=" . $filter_severity
. "&filter_fired=" . $filter_fired . "&filter_status=" . $filter_status
. "&search_string=" . $search_string . "&pagination=".$pagination."&offset=".$offset."&refr=".$config["refr"]."&pure=".$config["pure"];
pagination ($trapcount, $urlPagination, $offset, $pagination);
echo '
";
echo '
';
echo '
' . __('Status') . '
';
echo '
- ' . __('Validated');
echo '
';
echo '
- ' . __('Not validated');
echo '
';
echo '
';
echo '
' . __('Alert') . '
';
echo '
- ' .__('Fired');
echo '
';
echo '
- ' . __('Not fired');
echo '
';
echo '
';
echo '
' . __('Action') . '
';
echo '
- ' .__('Validate');
echo '
';
echo '
- ' . __('Delete');
echo '
';
echo '
';
echo '
'.__('Legend').'
';
foreach (get_priorities () as $num => $name) {
echo ''.$name.'';
echo '
';
}
echo '';
echo '
';
?>