Skip to main content

I am trying to get a custom pop up behaving correctly following the clicking of an event record in our skuid calendar view.


The pop up is a page include and the following query string (which i’m guessing is the problem) is sent: ActivityId={{$Model.All_Events.data.0.Id}}

If my calendar view has 10 cards being displayed with different events, and I click on any card, the pop up will show the same event record every time, regardless of what event card I click.

What do I need to do, to ensure that when an event card within a calendar is clicked, the pop up shows the event associated with the card clicked, and not some random event?

Your guess is exactly right. 

The merge syntax you are using - ActivityId={{$Model.All_Events.data.0.Id}} is what we call “Global” syntax. What is nice about this method is that you can use it wherever we process merges throughout the application.  The problem is that you don’t have “context”.  That merge will always retrieve the Id field from the FIRST row of the “All_Events” model.  (The 0 index).  You get the same event every time… 

Any data that is connected to a model is going to give you “row context”   If the calendar events in your calendar are bound to the All_Events model - and you simply use the field in braces  like this — {{Id}}  then the Id field will be specific to the row of the event you clicked on. 

You can test this by simply putting a template in the popup with {{Id}} to make sure different IDs are displayed for each event. 


This has resolved the issue, thanks very much for your help :)