2010-03-02 Pablo de la Concepción <pablo.concepcion@artica.es>
* include/functions_gis.php: Added a missing break and remove debugging code. * operation/gis_maps/render_view.php: Added code to render Gmap type of maps. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@2446 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
ee02b6fcd7
commit
57df567e55
|
@ -1,3 +1,11 @@
|
|||
2010-03-02 Pablo de la Concepción <pablo.concepcion@artica.es>
|
||||
|
||||
* include/functions_gis.php: Added a missing break and remove debugging
|
||||
code.
|
||||
|
||||
* operation/gis_maps/render_view.php: Added code to render Gmap type of
|
||||
maps.
|
||||
|
||||
2010-03-02 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* include/functions_gis.php: disabled the use of night version of
|
||||
|
|
|
@ -121,7 +121,6 @@ function printMap($idDiv, $iniZoom, $numLevelZooms, $latCenter, $lonCenter, $bas
|
|||
switch ($baselayer['gmap_type']) {
|
||||
case 'G_PHYSICAL_MAP':
|
||||
?>
|
||||
//var baseLayer = new OpenLayers.Layer.Google();
|
||||
var gphy = new OpenLayers.Layer.Google(
|
||||
"Google Physical",
|
||||
{type: G_PHYSICAL_MAP}
|
||||
|
@ -131,7 +130,6 @@ function printMap($idDiv, $iniZoom, $numLevelZooms, $latCenter, $lonCenter, $bas
|
|||
break;
|
||||
case 'G_HYBRID_MAP':
|
||||
?>
|
||||
alert("hibrid");
|
||||
var ghyb = new OpenLayers.Layer.Google(
|
||||
"Google Hybrid",
|
||||
{type: G_HYBRID_MAP, numZoomLevels: 20}
|
||||
|
@ -141,7 +139,6 @@ function printMap($idDiv, $iniZoom, $numLevelZooms, $latCenter, $lonCenter, $bas
|
|||
break;
|
||||
case 'G_SATELLITE_MAP':
|
||||
?>
|
||||
alert("satelite");
|
||||
var gsat = new OpenLayers.Layer.Google(
|
||||
"Google Satellite",
|
||||
{type: G_SATELLITE_MAP, numZoomLevels: 22}
|
||||
|
@ -151,7 +148,6 @@ function printMap($idDiv, $iniZoom, $numLevelZooms, $latCenter, $lonCenter, $bas
|
|||
break;
|
||||
default:
|
||||
?>
|
||||
alert("default");
|
||||
var gmap = new OpenLayers.Layer.Google(
|
||||
"Google Streets", // the default
|
||||
{numZoomLevels: 20}
|
||||
|
@ -160,7 +156,7 @@ function printMap($idDiv, $iniZoom, $numLevelZooms, $latCenter, $lonCenter, $bas
|
|||
<?php
|
||||
break;
|
||||
}
|
||||
|
||||
break;
|
||||
case 'Static_Image':
|
||||
?>
|
||||
var baseLayer = new OpenLayers.Layer.Image(
|
||||
|
|
|
@ -29,7 +29,8 @@ $map = get_db_row ('tgis_map', 'id_tgis_map', $idMap);
|
|||
$confMap = getMapConf($idMap);
|
||||
|
||||
$num_baselayer=0;
|
||||
|
||||
// Initialy there is no Gmap base layer.
|
||||
$gmap_layer = false;
|
||||
if ($confMap !== false) {
|
||||
foreach ($confMap as $mapC) {
|
||||
$baselayers[$num_baselayer]['typeBaseLayer'] = $mapC['connection_type'];
|
||||
|
@ -40,6 +41,13 @@ if ($confMap !== false) {
|
|||
case 'OSM':
|
||||
$baselayers[$num_baselayer]['url'] = $decodeJSON['url'];
|
||||
break;
|
||||
case 'Gmap':
|
||||
$baselayers[$num_baselayer]['gmap_type'] = $decodeJSON['gmap_type'];
|
||||
$baselayers[$num_baselayer]['gmap_key'] = $decodeJSON['gmap_key'];
|
||||
$gmap_key = $decodeJSON['gmap_key'];
|
||||
// Onece a Gmap base layer is found we mark it to import the API
|
||||
$gmap_layer = true;
|
||||
break;
|
||||
case 'Static_Image':
|
||||
$baselayers[$num_baselayer]['url'] = $decodeJSON['url'];
|
||||
$baselayers[$num_baselayer]['bb_left'] = $decodeJSON['bb_left'];
|
||||
|
@ -50,13 +58,19 @@ if ($confMap !== false) {
|
|||
$baselayers[$num_baselayer]['image_height'] = $decodeJSON['image_height'];
|
||||
break;
|
||||
}
|
||||
$baselayers[$num_baselayer]['url'] = $decodeJSON['url'];
|
||||
$num_baselayer++;
|
||||
if ($mapC['default_map_connection'] == 1) {
|
||||
$numZoomLevels = $mapC['num_zoom_levels'];
|
||||
}
|
||||
}
|
||||
}
|
||||
//debugPrint($gmap_layer);
|
||||
//debugPrint($gmap_key);
|
||||
if ($gmap_layer === true) {
|
||||
?>
|
||||
<script type="text/javascript" src="http://maps.google.com/maps?file=api&v=2&sensor=falsei&key=<?php echo $gmap_key ?>" ></script>
|
||||
<?php
|
||||
}
|
||||
|
||||
$controls = array('PanZoomBar', 'ScaleLine', 'Navigation', 'MousePosition', 'OverviewMap');
|
||||
|
||||
|
|
Loading…
Reference in New Issue