Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
1) Create new view Map
2) Create new display type : content pane
3) Set Format : Leaflet Map
4) Add filter location (geofiled) [ Content: Location:wkt (not empty) ]
5) Add context filter nid
6) Add views to panels node/%node (Views Argument input : Content ID)
7) Set views title
When field location is empty, Views appears just with the title and context links
Comment | File | Size | Author |
---|---|---|---|
#3 | leafet-views-empty-display-1944096-3.patch | 1.08 KB | Martijn Houtman |
#1 | leaflet-views-empty-display-1944096-1.patch | 854 bytes | sergiu.savva |
Comments
Comment #1
sergiu.savva CreditAttribution: sergiu.savva commentedTested on local machine
Comment #2
gcbThis patch doesn't work for me. I like the idea: perhaps it needs to disable the "hide empty map" checkbox in the views options?
Comment #3
Martijn Houtman CreditAttribution: Martijn Houtman commentedPlease try attached patch.
Comment #4
gmclelland CreditAttribution: gmclelland commentedComment #5
martins.bertins CreditAttribution: martins.bertins commented#3 worked for me
Comment #6
AdamPS CreditAttribution: AdamPS commentedI found that patch #3 also solves #1744856: View with "Hide empty" displays grey leaflet map - I'm not sure if I should mark them as duplicates, as the symptoms seem different.
Comment #7
timodwhit CreditAttribution: timodwhit commentedPatch in #3 also worked for me.
Comment #8
1kenthomas CreditAttribution: 1kenthomas commentedminiBump.
Comment #9
LewisNymanRTBC++
Comment #10
ac#3 RTBC - important fix
Comment #12
RdeBoerCommitted.
Available now in 7.x-1.x-dev and in 7.x-1.2 or later when released.
Thank you Martijn and Sergiu !
Rik