I am creating a custom Widget that is added to a WAB Developer Edition application. I am adding the editor and template widget to a bodyPanel div.
My main widget – GeoCapture gets loaded through the config.json inclusion. The GeoCapture Widget loads a dropdown menu that allows a uses to select what they want to do – 1) Add New Feature 2) Select Existing Feature.
Depending on the menu pick a second widget is created that has the UI for either 1) Add New Feature 2) Select Existing Feature.
For the Add New Feature widget:
1) I create and startup the search widget
2)Create the editor and templatepicker widgets and start the widgets.
I do not get the templatepicker templates displayed after editor and templatepicker widgets have been created (see image).
In the debugging tools for the AddWidget around line 201, I can see that at “featureLayers: templateLayers,” I have layers.
I suspect that the issue is that the editor and template picker are not getting instantiated and are not running widget startup on the map onLoad event. I likely need to do something like this “this.map.on("Load", lang.hitch(this, 'editWidgetCreate'));” to my Add New Feature widget. But I am not sure how to hitch to a separate widget.
Thanks in advance for any suggestions!
-Margo