Here is another widget for the Web App Builder.
Web AppBuilder for ArcGIS | Help - eLocate Widget
Features:
List of the latest enhancements and changes:
Older Versions
Thanks Robert. Added to the Web AppBuilder Developer Edition - Customization Resource List
Robert, when adding then editing a new map coordinate, the sample coordinates are not taking. I take that back....they do take, but you have to exit totally out of the widget edit, then back in. So, I guess this can just be a comment for anyone else that comes across this.
Hi Robert,
Thanks a million for adding another wonderful and very useful widget to your collection of Custom Widgets for the Web AppBuilder 1.2.
I needed this Enhanced Locate Widget because of the way you can locate points based on Decimal Degrees and also perform Reverse Geocoding to find the approximate street address of any point along a street segment.
It works flawlessly when you add your Enhanced Locate Widget 1.2 to a new map.
Here I am creating a New Map.
Select the Default Template
Enter the Title and Description
Open the Widget Tab and select the In Panel place holder number 1
Select Enhanced Locate from the Widget Gallery
Configure Enhanced Locate
Open the Address Inspector Tab
Drag the Address Inspector on to a street segment.
The Street Address is returned.
This is perfect!
However, I ran into a problem when I tried to duplicate an existing app and add your Enhanced Locate widget.
Edit App Info
Edit the App = Enhanced Search Test
Open the Widget Tab. This app already has a few of the standard widgets.
Select the In-Panel place holder number 1.
Select Enhanced Locate
The Application hangs at this stage!
I had an Enhancement Request.
In the Flex version of your Enhanced Locate Widget, you could locate an address point as shown below.
http://www.tapasdas.com/Maps/Desktops/web27
In the Flex version of your Enhanced Search Widget, you had an option to Use existing Locate Widget graphics.
You could define a 2-mile buffer around your Address Point and Search for Schools.
And just like magic, all the Schools within 2 miles of your address point will appear!
This was a very powerful feature.
It made it very easy and intuitive for the end user to find entities within a given radius of their home address.
I was wondering if you could add this option to your Enhanced Search Widget for the JavaScript version.
I am amazed how fast you are narrowing the gap between the powerful desktop Flex apps that we enjoyed for 8 years and this new Web AppBuilder platform that runs on all devices and all browsers without a plugin.
Hi Robert,
I found another minor issue with your Enhanced Locate Widget 1.2
I am trying to limit the Coordinate Input choices to:
Decimal Degrees - based on the WGS 1984 Datum
Example Coordinates: -112.096814, 33.448138
Degrees, Minutes, Seconds - based on the WGS 1984 Datum
Example Coordinates: 112-5-48.53 W, 33-26-53.29 N
Web Mercator Meters - based on WGS 1984 Datum (major auxiliary sphere)
Example Coordinates: -12478560, 3954938
Note: All 3 refer to the same location.
The Decimal Degrees, and Web Mercator Meters work perfectly.
However, when I try to edit the DMS option, my selection does not stick.
Here I am editing the DMS input method.
I am selecting the Degrees Minutes Seconds (DMS) option.
I am entering my Example Coordinates in DMS, making sure to include the W and N.
I am saving my changes
I am Configuring the Enhanced Locate Widget to make sure my edits were saved.
I am editing the DMS option.
The Input Units got reverted back to Decimal Degrees (DD).
So, when I try to use my example DMS values:
Longitude = 112-5-48.53 W
Latitude = 33-26-53.29 N
It takes me to China!
It is reading the input coordinates as Decimal Degrees.
It is ignoring the W sign, and reading this as an East Longitude.
I also found another issue.
I could not add an In-Panel Widget after the Enhanced Locate was added.
I am trying to add the Enhanced Basemap Widget to an In-Panel placeholder.
I am selecting the Enhanced Basemap Widget
The application hangs!
Hi Robert,
I had another enhancement request.
When you click to activate the Address Inspector Tool, and then click on a street segment:
The Results and Popup pane shows the Street Address and the Coordinates of the point clicked on the map.
The coordinates being displayed are the map coordinates which are in Web Mercator Meters.
It would be better to change the labels to:
Easting (X):
Northing (Y):
Also, it would be a good idea to display the values rounded to 0 decimal places.
An even better option would be to project the map coordinates to Decimal Degrees based on the WGS84 datum and label them as:
Longitude (X):
Latitude (Y):
Rebecca,
The fact that the new map unit does not show the coordinate example, ylabel, xlabel, or wkid in the table after adding it is a bug and I have it fixed for the next release. Thanks for letting me know.
Tapas,
Thanks, I am working my way through all you comments and requests now.
Tapas,
I am not able to reproduce either of your applications hangs. I you can get it to happen again can you screen shot the web console and attach. The DD, DMS issue I have fixed for the next release. The coordinate on the reverse geocode I went in a different direction just for efficiency sake. It will just have:
Address: 1700 W Washington St Phoenix, Arizona 85007
Coordinates: -12478449.68, 3954945.66
Reporting back the coordinates in the maps projection is the most efficient and there is no need for x and y labels.
Hi Robert,
I agree with your idea of displaying back the map coordinates with a label that says "Coordinates:"
This will give it the cleanest and simplest look.
It looks like my original WAB1.2 installation got corrupted. This was preventing me from adding Widgets.
So, I started with a fresh installation of WAB1.2. Everything is working fine now.
Sorry, I wasted your time.
All your 8 Custom Widgets are working smoothly.
Elevation Profile Widget 1.2
Enhanced Basemap Gallery Beta 1.1
Enhanced Bookmark Widget 1.2
Enhanced Located Widget 1.2
Enhanced Search Widget 1.2.0.3
Google Street View 1.2
Identify Widget 1.2.0.2
Share Widget 1.2.0.1
I started with a fresh install of WAB1.2 and added them to the
D:\WAB15\client\stemapp\widgets folder.
When I started node.js, all your 8 custom widgets were inserted correctly.
I created a new app using the default template
I named it Locate_2
Added the Enhanced Basemap Widget
Added the Enhanced Locate Widget
Added the Enhanced Search Widget
Saved the app and duplicated it as Locate_3
Added the Enhanced Bookmark Widget
There were no errors reported by Fiddler.
Everything is working properly with this fresh install.
Looking forward to your next release of eLocate!
Hi Robert,
I did not encounter anymore issues adding your Enhanced Locate Widget 1.2 after I started from scratch with a new installation of Web AppBuilder 1.2
All your 8 Custom Widgets are working smoothly.
I tested your Enhanced Locate Widget as in In-Panel Widget on the Foldable Theme.
http://www.tapasdas.com/Maps/Phones/app74
I like how the input boxes get populated the moment you click on the example coordinates. This is better than the Flex version!
Works flawlessly. I like how the widget controls matches the style color.
I tested your Enhanced Locate Widget on the Header Controller using the Jewelry Box Theme. I like the way the Layer List Widget flies in and out from the left on this theme to show/hide the Table of Contents.
http://www.tapasdas.com/Maps/Phones/app75
Your Address Inspector Tool works like a charm running reverse geocoding on the fly and returning the Street Address.
I was trying to think of a shorter label for the Address Inspector Tab. It gets partially cut off when added as a header widget.
The Box Theme which has an even more narrower width presents a challenge.
It seems like there are two tabs that have the same label reading Address.
When you open the Coordinates Tab in the Box Theme, the Example Coordinates does not have enough space. It is running over.
Also, the Latitude Label does not show up.
I like the horizontal scrollbar. This allows me to access the drop down arrow when I scroll to the right.
Tapas,
Good info. I have addressed the BoxTheme issues now for the next release.
Robert,
Thanks! I would be looking forward to your next release.
I was thinking of an alternate way to name the 3rd tab label which is overflowing.
Perhaps change "Address Inspector" to "Show Address"
This way all 4 tab labels will remain distinct, even if a few letters are cut off at the end:
Address
Coordinates
Show Address
Results
Here is another thought.
How about changing "Address Inspector" to "Inspect Address" or "Inspector", or "Inspect"
The 4 labels will read:
Address
Coordinates
Inspect Address
Results
Tapas,
I had already chosen to go with "Inspector". Thanks
This widget is boss. It works. Robert you have hit another home run for the team.
Is anyone else having an issue with the country code not working for the address search?
I added my country code and ran an address search but I get results from multiple countries.
Michael,
Thanks for informing me. I have it fixed in 1.2.0.2
Perfect, thank you Robert!
Anyone else having an issue with the application hanging? After an address search, the locator will zoom to the location and loop the map progress indicator indefinitely. It seems to work without the MPI turned on.
Leo,
This seems to be a zoom timing issue and I will have it fixed in the next release.
Hi Robert,
I have the default Foldable theme, a bunch of your widgets in our app, but eLocate looks like it has a CSS issue with tabs crowding slightly too close together. The 's' in Coordinates is cut off:
It looks like this in both Chrome and IE.
Kevin,
This is the expected behavior for the tabs. Tabs are not sized based on their titles they are equally sized based on the number of tabs thus the cutting off of the longer "Coordinates" label. If this is a concern then you will have to adjust the default width of the widget in your main config.json.
Hi Robert,
fyi, I found a few spelling typos in eLocate/nls/strings.js :
reverseDescLabel: "Use the inspect address tool to click on the map and loacte the addrress",
reversegeocodefailtitle: "Address Instpection Failed",
Works perfectly though for us. Our users like this widget. Cheers & Happy New Year!
Robert,
This app is just what I'm looking for. I'm a recent convert to WAB from Flex (having used many of your custom flex apps) but am having trouble deploying your custom WAB app. I downloaded, unzipped, and put it in my /clients/stemapp/widgets folder but when I edit a new application, it's not showing up to pick from as an option to deploy.
I'm using WAB Developer Edition 1.3. Any help is appreciated.
Link,
It sounds like you did all the steps correctly... In the /client/stemapp/widgets folder you now have a eLocate folder that has:
Right? Did you try restarting your WAB?
Just noticed that the unzipping added an additional eLocate folder in the path: \client\stemapp\widgets\eLocate\eLocate
The top level eLocate folder also included a file: "Older enhancements or changes.txt".
I have eliminated the extra folder in the path and restarted WAB. All is well. Many thanks.
Link,
just a quick note on the double folder name....Robert has his packaged in the folder, which is nice. Other publishers may not and if you "unzip here" instead of a new folder, you may have the widgets overwrite common files. [I had this happen before]. So, if you allow it to "unzip to <widget or new folder name>, you may get the double folder name and have to move it....but better than trying to sort the other, if not packaged nicely.
my opinion.
Along those lines as well is if you download a widget that some one has on GitHub then it will likely be in a parent folder in the zip that is called "something-master" and that will cause the widget to not work properly as well.
Dear Robert, I was going through the nls-strings file and I'd like to suggest a correction at line 24 - latitude: "Longitude (X)",
Other than that, so far so good
Kind Regards,
Shay.
Robert Scheitlin, GISP sorry to bug you, i have been configuring this amazing widget from you into my organisation's web app, however we use wkid: 27700 and an in-house geocode rest service, everything works except the inspector (reverse geocode) tab (works with the ESRI rest service) which i am guessing is because of this.map being in a different wkid, is there a part of the code i can alter to make this aspect work? because the request being passed to our rest service are that of WGS 84.
Thank you for your amazing help
Baba
Baba,
I am not sure why you would be having a problem as the widget is already developed to handle the map being in a different spatial reference then 102100. as you can see in the the createAddressInspectorResult function I will project the reverse geocode result into the map spatial reference. Are you saying that your locator is not in the same spatial reference as your data?
Thanks for the quick response Robert, they are all in the same SR, but not returning any address, however, this is not suppose to be the case as our geocoding service are being used rGeocode in various other applications. Also while examining the widget js, i found out this , but ours throw out outSR as default, could this be a problem? and how can i change this?
Thank you again.
Baba
Baba,
Are you saying that your ArcGIS Server is 9.x?
Hi Robert,
my ArcGIS Server is 10.x, so I don't expect this to affect the reverse geocoding request from this.map......I have even tested the request call on my geocoder and it returned an address but not with the Inspector.
Thanks
Baba
Baba,
If you are using a 10.x server then that comment and code about 9.x has nothing to do with you. Have you check your browsers web console to see if there are any errors when trying to do an address inspection?
Hi Robert,
Thanks for the replies, yes there are errors which I will be happy to show you in a screenshot but can't do that at the moment as I am off-site, hope you don't mind me showing them to you tomorrow? am sure am there is something I might be doing wrong.
Regards
Baba
Thank for your assistance, as I mentioned the last reply, here is the screen shot of the error returned
Regards
Baba
Baba,
unfortunately this error just tells me that the issue is coming from your Geocode service. Is this service or better yet your app public so I can do some testing?
Thank you for the quick response, no am afraid the service is not accessible publicly at the moment and the Apps too are designed for internal use only. I guess this is where I will have to dig deeper myself, do you think a setting from the gecode service might be affecting it?
Regards
Baba
Baba,
It is really hard fro me to know. I have seen issues in the past with BNG and webmercator. I would look at the first error in your image above and the full url that is submitted what are the parameters in that url?
Hi Robert,
Here is a screenshot of the SOAP request form for the geocode service:
And here is a sample parameter passed as json:
And here is the parameter passed on map but not completing the "call" aspect (&callback=dojo.io.script.jsonp_dojoIoScript5._jsonpCallback)
Thank you
Baba
Baba,
Does the first link work for you just by clicking it?
Hi Robert,
Yes it does returning this:
{"address":{"Address":"10 SYLVAN HEIGHTS, 141 LONDON ROAD, ST ALBANS, HERTFORDSHIRE, AL1 1SX","LOCATOR_FAMILY_ID":"200002747885"},"location":{"x":516074.07,"y":206152.2,"spatialReference":{"wkid":27700,"latestWkid":27700}}}
However, adding the "Callback" request returns an error:
Cheers
Baba
Hi Robert,
Sorry to bug you about this again but am still having a few issues with the reverse geocoding, the request from "Arcgis Geocode Service" returns a Json and stops there however, ours returns a with an additional request for a callback parameters: "callback=dojo.io.script.jsonp_dojoIoScript4._jsonpCallback".
Please assist me, is there a way to take out the callback request or rectify it from the service end?
Thanks a lot
Baba
Baba,
Having a call back is nothing specific to you. Call backs are added to esri JS API RESTful requests all the time. Unfortunately there is no more help I provide without having access to your service.
Hi Roberts,
Thank you for the wonderful replies, i figured out where the issue is. It's an issue of format been returned by the server (CORS), by passing that with a proxy seem to do the trick.
And again thanks for the awesome help you have been dishing out here. We in the UK are just grasping the concepts of WAB. Appreciated
Regards
Baba
Robert, just a small request, I think it would be good if the address inspector tool became inactive when the widget is closed.
Ryan,
Thanks fr the input. I will add that to the next release.
Can this widget include USNG or MGRS coordinates?
Christina,
Sure that ability could be added as a future release enhancement. The requirement for this would be ArcGIS Server 10.3 or greater which sould not be an issue as the WAB default geometryService is a 10.4 one.