koopjs / winnow

Deprecated
Apache License 2.0
90 stars 18 forks source link

Add support for point geometry #202

Closed jahndis closed 2 years ago

jahndis commented 2 years ago

Adds support for the geometry query param to be Point coordinates as specified by the esriGeometryPoint geometryType https://developers.arcgis.com/rest/services-reference/enterprise/query-feature-service-layer-.htm

This prevents an error in koop when using geoservices output for a link like: https://featureserver.com/provider/id/FeatureServer/0/query?f=json&geometryType=esriGeometryPoint&geometry=7652714.335571289%2C-1985856.184782909&geometryType=esriGeometryPoint&inSR=102100&outSR=102100

Added tests for this case, and monkey patched our version of koop to verify the fix works in our case. Resolves https://github.com/koopjs/winnow/issues/203

rgwozdz commented 2 years ago

Does geometry filtering work when you supply only a point? If so, I think you should add a test case to the integration test suite for filtering https://github.com/koopjs/winnow/blob/master/test/integration/filter.spec.js.

rgwozdz commented 2 years ago

Does geometry filtering work when you supply only a point? If so, I think you should add a test case to the integration test suite for filtering https://github.com/koopjs/winnow/blob/master/test/integration/filter.spec.js.

I've added an integration test that demos that this works. Thanks for the contribution.