backdrop-contrib / leaflet

Backdrop CMS Integration with the Leaflet map scripting library.
https://backdropcms.org/project/leaflet
GNU General Public License v2.0
2 stars 2 forks source link

Display OSM OpenWeatherMap layers #39

Closed oadaeh closed 7 months ago

oadaeh commented 1 year ago

Hello @indigoxela. Thank you for your efforts in improving and maintaining this module. It works so much better than the alternative. I have the main installed and working, including a view of multiple locations. Then I enabled the Leaflet More Maps module to see what it provided, and found and enabled the OSM OpenWeatherMap, but it doesn't display the precipitation or pressure layers, neither on a node or on a view. Is there something more that needs to do than select it as the Map? Thank you.

indigoxela commented 1 year ago

Is there something more that needs to do than select it as the Map?

It seems like they changed the whole API for that, so there's probably no immediate solution for you.

indigoxela commented 1 year ago

What I can see so far: the D7 version just removed that map, as it no longer works.

There are additional (new) implementations for D8+, which also seem to struggle a bit...

It's probably best to remove OpenWeatherMap from the B1 version of Leaflet integration and possibly put it in its own (sub-)module, but that looks like a lot of effort. And personally, I don't need it.

@oadaeh what do you think?

oadaeh commented 1 year ago

Thanks for digging into that. I hadn't seen that it had been removed from D7, but I was only looking in the issue queue. I don't really need it, but it would be nice to have to go with what I'm building, so I'll take a look at it and see what the effort level is.

indigoxela commented 1 year ago

I think, the old API is still functioning - one has to register an API key, though.

But I'm not sure, how long that API version will still be available. So we could update the module to handle the API key and things would work again... but how long?

indigoxela commented 1 year ago

If you're willing to take the risk - the change for adding API-key handling and updating the tile url is fairly minimal.

indigoxela commented 1 year ago

@oadaeh here's a quick experiment: https://github.com/backdrop-contrib/leaflet/pull/40

oadaeh commented 1 year ago

Wow. Okay. I was actually wondering if it might be better to port a more current and maintained module focused on weather and just let the OpenWeatherMap go.

oadaeh commented 1 year ago

I'll try out what you've done here.

indigoxela commented 1 year ago

It's still a topic to discuss, if this is future proof enough to merge. :grinning: Just an experiment.

indigoxela commented 7 months ago

Two years later I'm assuming that there's not enough interest in this feature, anyway. :wink: Feel free to reopen, if there are any new findings or ideas.