From: Anton Khorev Date: Wed, 5 Oct 2022 21:42:04 +0000 (+0300) Subject: Load note from edit link with remote control X-Git-Tag: live~954^2 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/a419f8890a66e584501b831aba9d1fdcbc6894bc Load note from edit link with remote control --- diff --git a/app/assets/javascripts/index.js b/app/assets/javascripts/index.js index 5ba36a455..e5590c9f7 100644 --- a/app/assets/javascripts/index.js +++ b/app/assets/javascripts/index.js @@ -246,8 +246,8 @@ $(document).ready(function () { }); function remoteEditHandler(bbox, object) { - var loaded = false, - url, + var remoteEditHost = "http://127.0.0.1:8111", + osmHost = location.protocol + "//" + location.host, query = { left: bbox.getWest() - 0.0001, top: bbox.getNorth() + 0.0001, @@ -255,25 +255,31 @@ $(document).ready(function () { bottom: bbox.getSouth() - 0.0001 }; - url = "http://127.0.0.1:8111/load_and_zoom?"; - - if (object) query.select = object.type + object.id; - - var iframe = $("