diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index f35a05608f..0caa0e6524 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,10 @@ +2010-01-27 Miguel de Dios + + * operation/gis_maps/render_view.php: add the check if there aren't any + connection to map. + + * operation/menu.php: change parameter "id" to "id_map". + 2010-01-27 Miguel de Dios * include/functions_gis.php: add function "deleteMap" for to delete the map diff --git a/pandora_console/operation/gis_maps/render_view.php b/pandora_console/operation/gis_maps/render_view.php index 5ce76eb8f1..1bb9653009 100644 --- a/pandora_console/operation/gis_maps/render_view.php +++ b/pandora_console/operation/gis_maps/render_view.php @@ -27,15 +27,17 @@ $map = get_db_row ('tgis_map', 'id_tgis_map', $idMap); $confMap = getMapConf($idMap); $num_baselayer=0; -foreach ($confMap as $mapC) { - $baselayers[$num_baselayer]['typeBaseLayer'] = $mapC['connection_type']; - $baselayers[$num_baselayer]['name'] = $mapC['conection_name']; - $decodeJSON = json_decode($mapC['conection_data'], true); - $baselayers[$num_baselayer]['url'] = $decodeJSON['url']; - $num_baselayer++; - if ($mapC['default_map_connection'] == 1) { - $numZoomLevels = $mapC['num_zoom_levels']; +if ($confMap !== false) { + foreach ($confMap as $mapC) { + $baselayers[$num_baselayer]['typeBaseLayer'] = $mapC['connection_type']; + $baselayers[$num_baselayer]['name'] = $mapC['conection_name']; + $decodeJSON = json_decode($mapC['conection_data'], true); + $baselayers[$num_baselayer]['url'] = $decodeJSON['url']; + $num_baselayer++; + if ($mapC['default_map_connection'] == 1) { + $numZoomLevels = $mapC['num_zoom_levels']; + } } } diff --git a/pandora_console/operation/menu.php b/pandora_console/operation/menu.php index 20210ebc4a..a1d5ba6989 100644 --- a/pandora_console/operation/menu.php +++ b/pandora_console/operation/menu.php @@ -79,8 +79,8 @@ if (give_acl ($config['id_user'], 0, "AR")) { if (! give_acl ($config["id_user"], $gisMap["group_id"], "AR")) { continue; } - $sub["operation/gis_maps/render_view&id=".$gisMap["id_tgis_map"]]["text"] = mb_substr ($gisMap["map_name"], 0, 15); - $sub["operation/gis_maps/render_view&id=".$gisMap["id_tgis_map"]]["refr"] = 0; + $sub["operation/gis_maps/render_view&map_id=".$gisMap["id_tgis_map"]]["text"] = mb_substr ($gisMap["map_name"], 0, 15); + $sub["operation/gis_maps/render_view&map_id=".$gisMap["id_tgis_map"]]["refr"] = 0; } $menu["gismaps"]["sub"] = $sub;