I'm using URL parameters to select to a polygon on open but the zoom level is usually 1 level to close. Is there an easy way to back it off?
WAB Dev. 2.11
Solved! Go to Solution.
Scott,
The only way you can fix this is to modify the MapUrlParamsHandler.js file selectFeatures method. Where it does the map.setExtent.
Scott,
The only way you can fix this is to modify the MapUrlParamsHandler.js file selectFeatures method. Where it does the map.setExtent.
I see that around line 400 but it isn't clear how to make an adjustment. I was hoping it was a simple zoom level but it looks like the extent sets a minx & y etc.
Scott,
You just use the extent classes expand method. i.e.
map.setExtent(resultExtent.expand(1.2, true));
That worked great. I pushed it out a little more even. As a mapper dabbling in code, I really appreciate the help you offer here.