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

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

sergiu.savva’s picture

Status: Active » Needs review
FileSize
854 bytes

Tested on local machine

gcb’s picture

Issue summary: View changes
Status: Needs review » Needs work

This patch doesn't work for me. I like the idea: perhaps it needs to disable the "hide empty map" checkbox in the views options?

Martijn Houtman’s picture

Please try attached patch.

gmclelland’s picture

Status: Needs work » Needs review
martins.bertins’s picture

#3 worked for me

AdamPS’s picture

Status: Needs review » Reviewed & tested by the community

I 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.

timodwhit’s picture

Patch in #3 also worked for me.

1kenthomas’s picture

miniBump.

LewisNyman’s picture

RTBC++

ac’s picture

#3 RTBC - important fix

RdeBoer’s picture

Assigned: Unassigned » RdeBoer
Status: Reviewed & tested by the community » Fixed

Committed.
Available now in 7.x-1.x-dev and in 7.x-1.2 or later when released.

Thank you Martijn and Sergiu !

Rik

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.