2011-04-12 Juan Manuel Ramon <juanmanuel.ramon@artica.es>

* extensions/users_connected.php
	operation/incidents/incident.list.php
	godmode/agentes/module_manager.php: Fixed some mistakes of my last 
	commit. 




git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4194 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
juanmanuelr 2011-04-12 16:58:11 +00:00
parent 30a21a8354
commit 9a00eb8a84
4 changed files with 26 additions and 11 deletions

View File

@ -1,3 +1,10 @@
2011-04-12 Juan Manuel Ramon <juanmanuel.ramon@artica.es>
* extensions/users_connected.php
operation/incidents/incident.list.php
godmode/agentes/module_manager.php: Fixed some mistakes of my last
commit.
2011-04-12 Miguel de Dios <miguel.dedios@artica.es> 2011-04-12 Miguel de Dios <miguel.dedios@artica.es>
* include/functions_graph.php: added constants for some graphs. Added * include/functions_graph.php: added constants for some graphs. Added

View File

@ -35,10 +35,12 @@ function users_extension_main_god ($god = true) {
$sql = "SELECT id_usuario, ip_origen, fecha, accion $sql = "SELECT id_usuario, ip_origen, fecha, accion
FROM tsesion FROM tsesion
WHERE descripcion = 'Logged in' AND utimestamp > (UNIX_TIMESTAMP(NOW()) - 3600) GROUP BY id_usuario, ip_origen, accion"; WHERE descripcion = 'Logged in' AND utimestamp > (UNIX_TIMESTAMP(NOW()) - 3600) GROUP BY id_usuario, ip_origen, accion";
break;
case "postgresql": case "postgresql":
$sql = "SELECT id_usuario, ip_origen, fecha, accion $sql = "SELECT id_usuario, ip_origen, fecha, accion
FROM tsesion FROM tsesion
WHERE descripcion = 'Logged in' AND utimestamp > (ceil(date_part('epoch', CURRENT_TIMESTAMP)) - 3600) GROUP BY id_usuario, ip_origen, accion"; WHERE descripcion = 'Logged in' AND utimestamp > (ceil(date_part('epoch', CURRENT_TIMESTAMP)) - 3600) GROUP BY id_usuario, ip_origen, accion";
break;
case "oracle": case "oracle":
$sql = "SELECT id_usuario, ip_origen, fecha, accion $sql = "SELECT id_usuario, ip_origen, fecha, accion
FROM tsesion FROM tsesion

View File

@ -187,7 +187,7 @@ switch ($sortField) {
switch ($config["dbtype"]) { switch ($config["dbtype"]) {
case "mysql": case "mysql":
case "postgresql": case "postgresql":
$order[] = array('field' => 'dbms_lob.substr(tagente_modulo.nombre,4000,1)', 'order' => 'DESC'); $order[] = array('field' => 'tagente_modulo.nombre', 'order' => 'DESC');
break; break;
case "oracle": case "oracle":
$order[] = array('field' => 'dbms_lob.substr(tagente_modulo.nombre,4000,1)', 'order' => 'DESC'); $order[] = array('field' => 'dbms_lob.substr(tagente_modulo.nombre,4000,1)', 'order' => 'DESC');
@ -244,7 +244,7 @@ switch ($sortField) {
switch ($config["dbtype"]) { switch ($config["dbtype"]) {
case "mysql": case "mysql":
case "postgresql": case "postgresql":
$order[] = array('field' => 'dbms_lob.substr(nombre,4000,1)', 'order' => 'ASC'); $order[] = array('field' => 'nombre', 'order' => 'ASC');
break; break;
case "oracle": case "oracle":
$order[] = array('field' => 'dbms_lob.substr(nombre,4000,1)', 'order' => 'ASC'); $order[] = array('field' => 'dbms_lob.substr(nombre,4000,1)', 'order' => 'ASC');

View File

@ -22,21 +22,27 @@ global $result_status;
global $result_groups; global $result_groups;
global $result_resolutions; global $result_resolutions;
foreach($result_status['status'] as $st) { if (!empty($result_status)) {
$status[$st['id']] = $st['name']; foreach($result_status['status'] as $st) {
$status[$st['id']] = $st['name'];
}
} }
// Add special status cases // Add special status cases
$status[0] = __('Any'); $status[0] = __('Any');
$status[-10] = __('Not closed'); $status[-10] = __('Not closed');
if (!empty($result_groups)) {
foreach($result_groups['group'] as $gr) { foreach($result_groups['group'] as $gr) {
$groups[$gr['id']] = $gr['name']; $groups[$gr['id']] = $gr['name'];
}
}
else {
$groups = array();
} }
$resolutions[0] = __('None'); $resolutions[0] = __('None');
foreach($result_resolutions['resolution'] as $res) { if (!empty($result_resolutions)) {
$resolutions[$res['id']] = $res['name']; foreach($result_resolutions['resolution'] as $res) {
$resolutions[$res['id']] = $res['name'];
}
} }
echo '<form method="post">'; echo '<form method="post">';