MapStore2 icon indicating copy to clipboard operation
MapStore2 copied to clipboard

FeatureEditor - Restrict editing by geometric area

Open Gaetanbrl opened this issue 6 months ago • 0 comments

Target branch : master

Description

link to https://groups.google.com/g/mapstore-developers/c/6KhmNTJzpDc

This improvement will change the featureEditor plugin to allow to limit attributes table features loading by a geometric area (WKT or GeoJSON) for non ADMIN users.

To activate this restriction, the user (with correct access) will configure FeatureEditor plugin to set a new restricedArea params section :

    "restrictedArea": {
      "url": "/my_geojson_or_wkt",
      "raw": "POLYGON ((-1.625007 48.12657, -1.625007 48.134647, -1.603028 48.134647, -1.603028 48.12657, -1.625007 48.12657))",
      "operator": "WITHIN"
    }

Where :

  • Operator <string> : WITHIN or INTERSECTS or CONTAINS
  • raw <string> : geometry GEOJSON or WKT
  • url <string> : path or URI (Will be use instead of raw if both are defined)

About sync and request, this area will be insert in SpatialField array filters with Viewport and others Filters.

In addition, an icon show that the restriction by area is currently active (left) :

image

Gaetanbrl avatar Aug 21 '24 12:08 Gaetanbrl