Wirecloud geojson in a map

156 Views Asked by At

Hello i'm trylling to show an entity with geojson data in a map inside of Wirecloud. The data comes from my own instance of Orion. Here you have some screenshots where you can see the data from Orion and the configuration.

General configuration

Entity to POI configuration

Dashboard, Json editor is just to show the data

If i change the lat and long and i put it in a normal attribute with name, it works but in the geojson array it doesn't work.

Can someone tell me what i'm doing wrong.

Thanks

3

There are 3 best solutions below

0
On BEST ANSWER

After some days of working, I saw that the version in the repo of the component "NGSI Entity 2 PoI operator" is hightest than the one that it's in the Wirecloud's marketplace, in the last commits i saw that geojson support was added so i tried it but it didn't work so I forked the repo and i fixed it.

Here it is my fixed version. https://github.com/xXcoronaXx/ngsi-entity2poi-operator

1
On

Your coordinates are swapped in the coordinates array. Please take into account that the order of coordinates in GeoJSON is [long, lat]

thanks

0
On

The problem is the version of the map-viewer widget you were using. Take into account that we have recently released version 2.6.0, and this is the first version of the map-viewer widget supporting geojson. You can download it from github.

Once you upgrade this widget, you can change the Coordinates attribute setting of the ngsientity2poi operator to location as this is the attribute containing the geojson geometry to be used to represent the PoI.