AnsweredAssumed Answered

Creating feature in hosted feature layer published on AGOL

Question asked by emiskdev1 on Feb 27, 2017
Latest reply on Mar 2, 2017 by rscheitlin

We have created application using Developer edition of WAB and it's using one Web Map and in that web map we have one hosted layer also. We have one Custom widget for adding co-ordinates,Once user enters all co-ordinates (lat/lng) user can click on finish button and this will create a feature in hosted feature layer published on AGOL.

 

I have done 

 

_finishGeom: function() {
var poly = new esri.geometry.Polygon();
var ring = new Array();
var firstpoint = null;
var points = this.cordTable.getData();
array.forEach(points, lang.hitch(this, function (point) {
var p = new esri.geometry.Point(point.lat, point.lng);
ring.push(p);
if (firstpoint == null) {
firstpoint = p;
}
}));
ring.push(firstpoint);
poly.addRing(ring);
},

 

Now how to add feature to hosted feature which is shared as part of Web Map using AGOL. I need coding part only all other configuration is done at server side

Outcomes