FullCalendar hover and description display (v2023)

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
philmills
User
Posts: 559

FullCalendar hover and description display (v2023)

Post by philmills »

v2023
Event hover seems to work only in month view, which means that you can't see the event description there
How can I activate it in all views - Week, Day, Agenda ?

Also how can I add an addional field into the hover window?
and how can I add an additonal field into the Day and list views?


arbei
User
Posts: 9390

Post by arbei »

With v2023 you need to add your own JsRender template in Page_Foot server event to override (with a lower data-seq) the original template:

<script type="text/html" data-name="event-popover" data-seq="10">
{{if extendedProps.timeSpan}}
<p>{{:extendedProps.timeSpan}}</p>
{{/if}}
{{:extendedProps.description}}
</script>

With v2024 you may simply use CustomTemplatePopover.

Currently the popover is only used in month view.

To add an additonal field into the Day and List views, you may use FullCalendar's Event Render Hooks.


philmills
User
Posts: 559

Post by philmills »

Ok thanks, I'll play with this a little


josejad
User
Posts: 117
Location: Spain

Post by josejad »

Hi,

How to show popover in DayGridWeek?

I've found this post answering my question, but I'm not able to make it work. (v2024)

Not sure if this phrase "Currently the popover is only used in month view." means it can be done, or it can't be done currently.

I've tried to show extendedprops to see if there some property setting when the popover must be shown

Thanks¡


arbei
User
Posts: 9390

Post by arbei »

arbei wrote:

Currently the popover is only used in month view.

That means by default popover is only used for "dayGridMonth", not "dayGridWeek". However, you may try add your views, e.g. in Client Script (v2024)
ew.calendarOptions.popoverViews.push("dayGridWeek");


josejad
User
Posts: 117
Location: Spain

Post by josejad »

Thanks! It's working perfectly


Post Reply