From 051dd90450d3cc8fc2351eec5cb4e0b6f10a9931 Mon Sep 17 00:00:00 2001 From: Yohan Boniface Date: Tue, 17 Sep 2024 08:54:19 +0200 Subject: [PATCH] fix: editing coordinates manually would not be saved The primary coordinates is a two-elements Array in Point.coordinates, but FormBuilder does not know how to edit an Array, so we edit the `ui._latlngs` instead. The proper fix would have been to teach FormBuilder how to edit an Array, but that path is way longer, and given we plan to refactor it totally, let's wait for that. fix #2144 --- umap/static/umap/js/modules/data/features.js | 1 + 1 file changed, 1 insertion(+) diff --git a/umap/static/umap/js/modules/data/features.js b/umap/static/umap/js/modules/data/features.js index 4d16d2d8..4f213342 100644 --- a/umap/static/umap/js/modules/data/features.js +++ b/umap/static/umap/js/modules/data/features.js @@ -655,6 +655,7 @@ export class Point extends Feature { builder.restoreField('ui._latlng.lat') builder.restoreField('ui._latlng.lng') } + this.pullGeometry() this.zoomTo({ easing: false }) }, })