[Mapbender-commits] r7590 - trunk/mapbender/http/javascripts
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Mon Feb 14 05:31:25 EST 2011
Author: kmq
Date: 2011-02-14 02:31:25 -0800 (Mon, 14 Feb 2011)
New Revision: 7590
Modified:
trunk/mapbender/http/javascripts/mod_digitize_tab.php
Log:
continuing ticket #719. Didn't work the way it was supposed to
Modified: trunk/mapbender/http/javascripts/mod_digitize_tab.php
===================================================================
--- trunk/mapbender/http/javascripts/mod_digitize_tab.php 2011-02-14 09:00:13 UTC (rev 7589)
+++ trunk/mapbender/http/javascripts/mod_digitize_tab.php 2011-02-14 10:31:25 UTC (rev 7590)
@@ -2331,11 +2331,13 @@
str += ">\n\t\t";
var wfsConfIndices = getAvailableWfsForGeom(d.get(geometryIndex), wfsConf);
-// alert(wfsConfIndices.join(","));
var selected = false;
+ // set the current wfs_conf as the selected
+ // if wfs_conf is not yet set (for example when creating a new feature, just select the first one)
+ var selectedIndex = d.get(geometryIndex).wfs_conf || 0;
for (var i = 0; i < wfsConfIndices.length ; i++) {
str += "<option value='" + wfsConfIndices[i] + "'";
- if (!selected) {
+ if (i == selectedIndex ) {
str += " selected";
selected = true;
defaultIndex = parseInt(wfsConfIndices[i]);
More information about the Mapbender_commits
mailing list