AnsweredAssumed Answered

Feature Layer from JSON

Question asked by vakhtang_zuba on Sep 4, 2020
Latest reply on Sep 4, 2020 by bixb0012

Hi Guys,

i have some JSON data and wantto display it on map, but i cant.

what i do wrong?

 

var flayer = new FeatureLayer ({
    objectIdFieldName: "OBJECTID",
     globalIdFieldName: "",
     geometryType: "point",
   
fields: [
  {
   name: "OBJECTID",
   alias: "OBJECTID",
   type: "oid"
  },
  {
   name: "Wis_kam_ID",
   alias: "Wis_kameris_ID",
   type: "string",
   length: 12
  },
  {
   name: "nomeri_planSetze",
   alias: "nomeri_planSetze",
   type: "string",
   length: 50
  }],
  features: [{
    geometry: {
      x: 477262.23610000033,
      y: 4637311.2296999991
    }
  }],
  attributes: {
    OBJECTID: 1,
    Wis_kam_ID: "WA-AR-1",
    nomeri_planSetze: null,
  }
    })
    map.add(flayer)

Outcomes