geosolutions-it / MapStore2

The solution to create and share maps, dashboards, geostories with 3D support on the web. And it is open-source too!
https://mapstore.geosolutionsgroup.com/
Other
511 stars 398 forks source link

'Remove all annotations geometry' doesn't work properly without setting initial state #4182

Closed francoxyz closed 5 years ago

francoxyz commented 5 years ago

Description

Without setting the initial state:

     "annotations": {
      "config": {
        "multiGeometry": true,
        "validationErrors": {}
      },
      "format": "decimal",
      "defaultTextAnnotation": "New"
    },

When I create a new annotation geometry and I save it, the buttom 'Remove all annotations geometry' doesn't remove the annotation immediatly. The annotation is only removed after clicking on 'back' and 'confirm'

Anno

In case of Bug (otherwise remove this paragraph)

Browser Affected (use this site: https://www.whatsmybrowser.org/ for non expert users)

Browser Version Affected

Steps to reproduce

Expected Result

Current Result

Other useful information (optional):

See geosolutions-it/MapStore2#3852

kasongoyo commented 5 years ago

@francoperversi & @tdipisa. It seems to work as expected on my side. see

MapStore HomePage

MV88 commented 5 years ago

@kasongoyo have you removed the initial state of annotation in localConfig.json?

to me it seems not, notice how the pencil (with plus) does not disables.

please check if it is related to the mutliGeometry set to false (or not being set, i.e. defaults which is falsy).

kasongoyo commented 5 years ago

@kasongoyo have you removed the initial state of annotation in localConfig.json?

to me it seems not, notice how the pencil (with plus) does not disables.

please check if it is related to the mutliGeometry set to false (or not being set, i.e. defaults which is falsy).

@MV88 You're right. I forgot to remove the initial state. Now I can replicate, thanks