Panels integration

Created on 14 May 2015, about 9 years ago
Updated 18 April 2024, 3 months ago

Hi everybody,

I decided to introduce Panels integration for this module.
Yes, I know with the current version it is possible to insert a simple block in the Panel, but I used a totally different approach and created a custom and reusable panel pane and tweaked a few things in the module.

What are the features?

1) You can use multiple map instances on the same page. (see screenshot)
2) Each map instance can have it's own configuration.
3) Each map instance has a wrapper with unique ID (In case you want to attach a kitten to just one specific map).
4) Improved validation.
5) Address field is not required when you configure the pane - you can either use address or if it's empty then pane will use the coordinates. I really think the same way has to be used in the original logic.

In order to do this I had to tweak the initial code. Basically, settings array now has "container" element, which specifies a unique container for a certain map.
I also swapped body and footer div IDs to CLASS, which means that if you apply this patch then you have to watch out for your styling of body and footer - just tweak your styles to use class selectors instead of id selector.

ALSO, I removed width and height settings from the configuration form, and that is for the reason that I described here:
https://www.drupal.org/node/2487792 β†’ (I will try to suggest a patch asap).

Steps to get it working:

1) Apply the patch.
2) Clear cache.
3) Go to your panel and add "Location Map" pane from "Miscellaneous" category.
4) Edit your pane settings to configure your map.
5) Add more "Location Map" panes. And more...and more!

Well, I hope this will be useful for anyone. Any thoughts on this?
Cheers

πŸ“Œ Task
Status

Closed: outdated

Version

2.3

Component

Code

Created by

πŸ‡¦πŸ‡ΊAustralia barbun

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡¦Ukraine AstonVictor

    I'm closing it because the issue was created a long time ago without any further steps.

    if you still need it then raise a new one.
    thanks

Production build 0.69.0 2024