From: <fxp...@us...> - 2011-01-19 09:13:04
|
Revision: 7165 http://geonetwork.svn.sourceforge.net/geonetwork/?rev=7165&view=rev Author: fxprunayre Date: 2011-01-19 09:12:58 +0000 (Wed, 19 Jan 2011) Log Message: ----------- Open WMS browser panel if null layer name. Modified Paths: -------------- sandbox/guiwidgets/web/src/main/webapp/apps/js/GeoNetwork/lib/GeoNetwork/map/core/CatalogueInterface.js Modified: sandbox/guiwidgets/web/src/main/webapp/apps/js/GeoNetwork/lib/GeoNetwork/map/core/CatalogueInterface.js =================================================================== --- sandbox/guiwidgets/web/src/main/webapp/apps/js/GeoNetwork/lib/GeoNetwork/map/core/CatalogueInterface.js 2011-01-19 09:09:54 UTC (rev 7164) +++ sandbox/guiwidgets/web/src/main/webapp/apps/js/GeoNetwork/lib/GeoNetwork/map/core/CatalogueInterface.js 2011-01-19 09:12:58 UTC (rev 7165) @@ -181,12 +181,21 @@ if (layerList.length === 0) { return; } + + var onlineResource = layerList[0][1]; + /* if null layer name, open the WMS Browser panel */ + if (layerList[0][2]=='') { + GeoNetwork.WindowManager.showWindow("addwms"); + var panel = Ext.getCmp(GeoNetwork.WindowManager.getWindow("addwms").browserPanel.id); + panel.setURL(onlineResource); + return; + } + layerLoadingMask = new Ext.LoadMask(map.div, { msg: OpenLayers.Lang.translate('loadLayer.loadingMessage')}); layerLoadingMask.show(); - var onlineResource = layerList[0][1]; layers = layerList; var params = {'service': 'WMS', 'request': 'GetCapabilities', This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |