From efe71d5c71b72cf4d0ae76ee1cdfb730ea821945 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pablo=20de=20la=20Concepci=C3=B3n=20Sanz?= Date: Fri, 29 Jan 2010 15:47:40 +0000 Subject: [PATCH] =?UTF-8?q?2010-01-29=20=20Pablo=20de=20la=20Concepci?= =?UTF-8?q?=C3=B3n=20?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * operation/gis_maps/render_view.php: Fixed call to get_agent_names to get the names in the same case as they are in the DB. * operation/agentes/gis_view.php: Changed size of the map to be relative * include/functions_gis.php: Fixed the call to addPoint in getAgentMap to use the new parameters. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@2322 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 10 ++++++++++ pandora_console/include/functions_gis.php | 2 +- pandora_console/operation/agentes/gis_view.php | 2 +- pandora_console/operation/gis_maps/render_view.php | 3 ++- 4 files changed, 14 insertions(+), 3 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index c6afbffb61..28ae124a28 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,13 @@ +2010-01-29 Pablo de la ConcepciĆ³n + + * operation/gis_maps/render_view.php: Fixed call to get_agent_names to + get the names in the same case as they are in the DB. + + * operation/agentes/gis_view.php: Changed size of the map to be relative + + * include/functions_gis.php: Fixed the call to addPoint in getAgentMap + to use the new parameters. + 2010-01-29 Miguel de Dios * godmode/reporting/map_builder.php: use "clean_cache" in the deleting of diff --git a/pandora_console/include/functions_gis.php b/pandora_console/include/functions_gis.php index e8d30e5b65..75e74a48c9 100644 --- a/pandora_console/include/functions_gis.php +++ b/pandora_console/include/functions_gis.php @@ -591,6 +591,6 @@ function getAgentMap($agent_id, $heigth, $width, $show_history = false, $history /* TODO: only show the last history_time part of the path */ addPath("layer_for_agent_".$agent_name,$agent_id); } - addPoint("layer_for_agent_".$agent_name, $agent_name, $agent_position['last_latitude'], $agent_position['last_longitude'], $agent_icon); + addPoint("layer_for_agent_".$agent_name, $agent_name, $agent_position['last_latitude'], $agent_position['last_longitude'], $agent_icon, 20, 20, $agent_id, 'point_agent_info'); } ?> diff --git a/pandora_console/operation/agentes/gis_view.php b/pandora_console/operation/agentes/gis_view.php index 949796a047..1e1ad59d94 100644 --- a/pandora_console/operation/agentes/gis_view.php +++ b/pandora_console/operation/agentes/gis_view.php @@ -36,7 +36,7 @@ echo "

".__('Received data from')." ". $agent_name . "

"; echo "

" . __("Map with the last position/s") . " " . human_time_description ($period) ."

"; /* Map with the current position */ -echo "
"; +echo "
"; echo getAgentMap($agentId, "500px", "98%", true); echo "

" . __("Positional data from the last") . " " . human_time_description ($period) ."

"; diff --git a/pandora_console/operation/gis_maps/render_view.php b/pandora_console/operation/gis_maps/render_view.php index 1bb9653009..b9dbf8ed44 100644 --- a/pandora_console/operation/gis_maps/render_view.php +++ b/pandora_console/operation/gis_maps/render_view.php @@ -72,7 +72,8 @@ if ($layers != false) { foreach ($layers as $layer) { makeLayer($layer['layer_name'], $layer['view_layer']); - $agentNames = get_group_agents($layer['tgrupo_id_grupo']); + // calling get_group_agents with none to obtain the names in the same case as they are in the DB. + $agentNames = get_group_agents($layer['tgrupo_id_grupo'],false,'none'); foreach ($agentNames as $agentName) { $idAgent = get_agent_id($agentName); $coords = get_agent_last_coords($idAgent);