Hello, I am trying to update dynamically the events that are shown in the calendar, but I am not sure how to do it because I am seegin strange behaviours.
The user has month and week view in the calendar, when the user changes the view, I update the dates using the activeStart and activeEnd that we receive with the event "onViewRender", after that I hide the calendar, refresh the DataAction with the new dates received. in the OnAfterFetch of my DataAction, I add a NewEventSourceData, set my Calendar's EventSourceList to the result of the NewEventSourceData and refetch the events and show the calendar again.
The thing is that when switching views, after the switch, the calendar is always in month view.
The only way to make this work properly is retrieving all future events with my DataAction and and passing to the calendar, but I just want to fetch the events for a specific month.
I tried removing the default view from the calendar's advanced config and calculating the view depending on the activeStart/activeEnd (if difference is <= 7 it is weekView, otherwise if diff is 30, it is monthView), this still does not work.
I tried not hiding the calendar before refreshing the DataAction not working.
Can you help me on this?
Thanks in advance
" firstDay: 1, contentheight: 125, height:'80%', weekends: false, eventLimit:'True', scrollTimeReset: false, slotEventOverlap:true, buttonText: { month: 'month', week: 'week', day: 'day', list: 'list' }, header: { left: 'title', center: 'dayGridMonth,timeGridWeek', right: 'today prev,next' }, eventTimeFormat: { hour: '2-digit', minute: '2-digit', meridiem: false, hour12: false }, locale:'en', fixedWeekCount: false, selectConstraint: { daysOfWeek: [1, 2, 3, 4, 5] }, eventConstraint: { daysOfWeek: [1, 2, 3, 4, 5] }"
Hello José,
Can you add the module or a version of it for me to have a look?
Hello, here you have the OML.
In the Calendar Screen you have a Button to populate some dates in the DB. After that, refresh the page, it will show and empty calendar, and sometimes when changing the type of view, it doesn't show information.
Other times what happens is when swtiching the views, it stays always in month view (right now this is not happening but I am not sure what I changed)
Thanks for your help
EDIT: I updated the code with problem of not swithing the view when trying to dynamically fetching the data.
Dear José,
Thank you for your message and for using our component. We are committed to keeping our components up to date and addressing any questions or concerns whenever possible. Although some time has passed, we are continuously working to ensure that everything remains functional and useful for your projects.
Should you require further assistance, please do not hesitate to reach out via our website contact form at mediaweb.pt or send us a private message. We can help you achieve the desired functionality for your projects.
Best regards,
João Reis
mediaweb.pt