From 675de12a5df6b22b7a40ad117f71ae8f72bf1d43 Mon Sep 17 00:00:00 2001 From: Richard Schreiber Date: Fri, 26 Feb 2021 15:20:14 +0100 Subject: [PATCH] Geo fields: only confirm/overwrite if new lat/lon differ from existing coordinates --- src/pretix/static/pretixcontrol/js/ui/geo.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/pretix/static/pretixcontrol/js/ui/geo.js b/src/pretix/static/pretixcontrol/js/ui/geo.js index 3864c96bbf..158eb027c0 100644 --- a/src/pretix/static/pretixcontrol/js/ui/geo.js +++ b/src/pretix/static/pretixcontrol/js/ui/geo.js @@ -46,7 +46,10 @@ $(function () { lat = res.results[0].lat; lon = res.results[0].lon; - if (touched) { + if ($lat.val() == lat && $lon.val() == lon) { + $notifications.attr("data-notify", ""); + } + else if (touched) { $notifications.attr("data-notify", "confirm"); } else {