WEB Directions widget - Customize the stop name on the search form

526
1
05-17-2019 12:20 PM
Labels (1)
MrRock
by
New Contributor

I'm a newbie to ESRI Api Javascript and WAB. So I have been trying to put a textfield as  a label(alias) beside each stop field on the search form instead of using automatically generated numbers like 1, 2, 3... Users should be able to customize the stop name. It will be similar to the widget Route on the Flex version. Could anybody tell how to do that? I just attached an image showing a draft.

0 Kudos
1 Reply
VictorTey
Esri Contributor

Hi, Are you referring to a feature action?

https://developers.arcgis.com/web-appbuilder/sample-code/create-a-feature-action-in-your-widget.htm

The action can link to a form for the user to customize the stop name.

Alternative

https://developers.arcgis.com/javascript/latest/sample-code/sandbox/index.html?sample=popup-actions

and you can put forms in the content

var template = {
// autocasts as new PopupTemplate()
title: "Trail run",
content: "{name} <input type='text' name='firstname' value='whatever'>",
actions: [measureThisAction]
};

0 Kudos