AnsweredAssumed Answered

Why don't my attributes display when using editor widget from API 3.21?

Question asked by seabrooke on Jul 27, 2017
Latest reply on Aug 28, 2017 by cseabrooke

I'm new to JavaScript and the API. I'm trying to modify the default editing widget:

Default editing widget | ArcGIS API for JavaScript 3.21 

When I change the URL to my feature service, only one field  displays in the form. I tried different features from my service and still only one field displays. The field that displays is the  ‘Type ID Field’  in the layer. A snippet from my code:

var operationsPointLayer = new FeatureLayer("http://50.18.50.62:6080/arcgis/rest/services/FieldSeekerMobile3/FeatureServer/15", {
mode: FeatureLayer.MODE_ONDEMAND,
outfields: ["*"]
});

map.addLayers([operationsPointLayer]);
map.infoWindow.resize(400, 300);

function initEditing(event) {
var featureLayerInfos = arrayUtils.map(event.layers, function (layer) {
return { "featureLayer": layer.layer };
});

var settings = {
map: map,
layerInfos: featureLayerInfos
};
var params = {
settings: settings
};
var editorWidget = new Editor(params, 'editorDiv');
editorWidget.startup();

//snapping defaults to Cmd key in Mac & Ctrl key in PC
// specify 'snapKay' option only if you want a different key combination
// for snapping
map.enableSnapping();
}

 

Any suggestions will be appreciated.

Outcomes