#1093: When custom projection & resolutions set to map config, view and edit mode
map does not work
---------------------+------------------------------------------------------
Reporter: fxp | Owner: geonetwork-devel@…
Type: defect | Status: new
Priority: major | Milestone: v2.9.0
Component: General | Version: v2.8.0RC1
Keywords: |
---------------------+------------------------------------------------------
Sample config:
{{{
GeoNetwork.map.PROJECTION = "EPSG:28992";
GeoNetwork.map.EXTENT = new
OpenLayers.Bounds(-285401.92,22598.08,595401.92,903401.92);
GeoNetwork.map.RESOLUTIONS =
[3440.64,1720.32,860.16,430.08,215.04,107.52,53.76,26.88,13.44,6.72,3.36,1.68,0.84];
}}}
Error is:
{{{
Uncaught TypeError: Cannot read property 'length' of undefined
Layer.js:1143
OpenLayers.Layer.OpenLayers.Class.getResolutionForZoom Layer.js:1143
OpenLayers.Layer.OpenLayers.Class.getResolution Layer.js:1079
OpenLayers.Map.OpenLayers.Class.getResolution Map.js:2168
OpenLayers.Map.OpenLayers.Class.calculateBounds Map.js:1536
OpenLayers.Layer.OpenLayers.Class.getExtent Layer.js:1093
OpenLayers.Layer.OpenLayers.Class.redraw Layer.js:551
OpenLayers.Layer.HTTPRequest.OpenLayers.Class.redraw HTTPRequest.js:149
OpenLayers.Map.OpenLayers.Class.setBaseLayer Map.js:1237
OpenLayers.Map.OpenLayers.Class.addLayer Map.js:1033
createMap ExtentMap.js:140
initMapDiv
}}}
Add resolutions parameter to Maps created by ExtentMap solves the issue.
--
Ticket URL: <http://trac.osgeo.org/geonetwork/ticket/1093>
GeoNetwork opensource Developer website <http://sourceforge.net/projects/geonetwork/>
GeoNetwork opensource is a standards based, Free and Open Source catalog application to manage spatially referenced resources through the web. It provides powerful metadata editing and search functions as well as an embedded interactive web map viewer. This website contains information related to the development of the software.