[GRASS-SVN] r63059 - grass/trunk/gui/wxpython/web_services
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Nov 26 06:28:08 PST 2014
Author: turek
Date: 2014-11-26 06:28:08 -0800 (Wed, 26 Nov 2014)
New Revision: 63059
Modified:
grass/trunk/gui/wxpython/web_services/widgets.py
Log:
wx.web_services: fix for srs codes with urn
Modified: grass/trunk/gui/wxpython/web_services/widgets.py
===================================================================
--- grass/trunk/gui/wxpython/web_services/widgets.py 2014-11-26 14:25:52 UTC (rev 63058)
+++ grass/trunk/gui/wxpython/web_services/widgets.py 2014-11-26 14:28:08 UTC (rev 63059)
@@ -51,6 +51,7 @@
sys.path.append(rinwms_path)
from wms_base import WMSDriversInfo
+from srs import Srs
from grass.pydispatch.signal import Signal
@@ -644,7 +645,7 @@
if 'srs' not in self.drv_props['ignored_params']:
i_srs = self.params['srs'].GetSelection()
- epsg_num = int(self.projs_list[i_srs].split(':')[1])
+ epsg_num = int(self.projs_list[i_srs].split(':')[-1])
lcmd.append("srs=%s" % epsg_num)
for k in ['maxcols', 'maxrows', 'urlparams']:
@@ -702,12 +703,12 @@
if 'srs' not in self.drv_props['ignored_params']:
for proj in projs_list:
- proj_spl = proj.strip().split(':')
-
+ proj_code = Srs(proj.strip()).getcode()
+ proj_spl = proj_code.split(':')
if proj_spl[0].strip().lower() in self.drv_info.GetSrs():
try:
int(proj_spl[1])
- self.projs_list.append(proj)
+ self.projs_list.append(proj_code)
except ValueError, IndexError:
continue
More information about the grass-commit
mailing list