Pass ID in Calendar

I’m trying to use an event ID to open “Dynamic Modal” with Data Detail to view a single event, but I can’t, only if I use the start date or event title. Where can I change this ?

Please check my reply to the same question you asked in another topic…

Thanks Teodor, I didn’t receive the reply alert, I will try again.

I’m doing a test to pass the “id” to the Data Detail and it doesn’t work, only with the “title” and “start” data, I try to use a variable or pass value directly to the data detail but it doesn’t work. If I put a title it shows but not in modal.

Please explain a little more detailed what exactly are you doing and post some screenshots. “It does not work” doesn’t really help us identify your issue.

Ok, I use a Server connect to Api action to get values from table like example of calendar. I created a data_detail to open the data source with id selected from calendar in “Event Click”. If I use title ou date of start event work, but If I use id not work. As I can have two events with the same date I need to use the ID. It seems that I can only send pro data detail what appears in the calendar event (Date and title), as the ID of event does not appear, it doesn’t works. I tried to create a variable and present it with the ID value and it works, only in the data detail that doesn’t with dynamic modal.

Please post some screenshots of what exactly are you selecting and what events are you using in the calendar.

tela4 tela3 tela2 tela1

You need to just pass the event id to the data detail, no need of using a separate variable for this.

I tried to go directly and through variable and problem persists.

So what exactly the problem is then? What is the issue?
I just tested this and it works perfectly fine - setting a variable value or a data detail record using the event click dynamic event works great:

just exactly the same way as in the tutorial i sent you.

Works with start date and title but not with id.

I managed to recreate the problem, we are checking what’s wrong.

It seems the calendar returns the id as a string (https://fullcalendar.io/docs/v4/event-object), so it doesn’t match the data detail key.
To fix this use the to number formatter in the click event, so the code becomes like:

 dmx-on:eventclick="modal1.data_detail1.select($event.event.id.toNumber());"
1 Like

Thanks, works perfectly.