Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

using the Admin will not work #1

Open
JohnMica opened this issue Nov 26, 2019 · 14 comments
Open

using the Admin will not work #1

JohnMica opened this issue Nov 26, 2019 · 14 comments

Comments

@JohnMica
Copy link

Hi there,

I figured I could use your plugin instead of creating a new one from scratch.

Something strange is happening when using the Admin interface

  • all fields are editable except the Lat. / Long.
  • using the 'search' button in the Admin will not find anything at any time
    • I assume the search is trying to use the address fields from above but cannot do it properly ?

Using the .yaml file works as expected only if you know the coordinates, otherwise it doesnt work and I am not sure what is happening

@foxfabi
Copy link
Owner

foxfabi commented Nov 28, 2019

As you have determined, the coordinates are added with the search from the field values.

Try the latest release is v1.0.5 please.

@JohnMica
Copy link
Author

Thanks for the quick reply.
I couldn’t help to figure out that there is an external geolocation API service that determines the actual coordinates.
And i think it is under http only? (Could remember wrong) :)

@foxfabi
Copy link
Owner

foxfabi commented Nov 28, 2019

I'm using photon.komoot.de. It support HTTP and HTTPS.
In the latest release i use the protocoll relative url.
Check the url in leaflet-address.backend.js line 5.

@JohnMica
Copy link
Author

still not working using the admin - using your latest release - could it be the API is not working anymore ?
I saw that your errors are not emitting anything yet.

@foxfabi
Copy link
Owner

foxfabi commented Nov 28, 2019

maybe.. i'm on the road so i will check tomorrow. thanks for patience.

@foxfabi
Copy link
Owner

foxfabi commented Dec 12, 2019

i tested it again and all works fine.. can you provide an example of your search string?

@JohnMica
Copy link
Author

That is strange indeed.
The address was in - COVENTRY, United Kingdom.

@JohnMica
Copy link
Author

it does work somehow. not sure what happened there but it could be the API was down perhaps ?

@foxfabi
Copy link
Owner

foxfabi commented Dec 13, 2019

the api supports some osm_tags. maybe you can add some restrictions like place.

@JohnMica
Copy link
Author

not sure what actually happened but hey = I did manage to get a simple leaflet done :).
I'll add a setting for the scroll wheel zoom and PR it since it might get tricky to move passed the map section on phones and touch screens :)

@JohnMica JohnMica reopened this Dec 30, 2019
@JohnMica
Copy link
Author

JohnMica commented Dec 30, 2019

I believe I have figured out why it was not working.

Country code GB is not recognised by the API.
When using their homepage with the address inside the Admin, with the Country Code GB it doesnt work but without the country code or with the actual Country name it works (as seen in the images attached.

So maybe don't need the country code as GB but use the actual country name United Kindgdom and it works.

Maybe this happens for other countries as well ? I haven't checked that yet.

I've fixed it on my end but I modified some files (could do a PR if you want to - but more checks are needed) - my editor doesnt like script tags with TWIG templates so had to modify a bit the structure of the plugin.
Screenshot 2019-12-30 at 12 43 37

Screenshot 2019-12-30 at 12 43 25

@foxfabi
Copy link
Owner

foxfabi commented Dec 30, 2019

Glad to read that you found the cause. I'll look into it as soon as I can. I will gladly accept your amendment and review it.

@JohnMica
Copy link
Author

JohnMica commented Dec 30, 2019 via email

@foxfabi
Copy link
Owner

foxfabi commented Sep 8, 2022

Closed due to inactivity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants