I want to trigger an refresh events with a specific parameter when selecting a value in a select box.
I have my select box defined in a grails tag:
<g:select name="resourceId"
from="${Resource.list()}"
optionKey="id"
optionValue="name"
onchange="refreshCalendar()"/>
I understand that I can trigger a JS function with the onchange item in the tag.
refreshCalendar function:
$('#calendar').fullCalendar('refetchEvents')
My calendar is configured as:
$('#calendar').fullCalendar({
events: '${createLink(action:'loadSchedule' )}'
}
How can I now provide the calendar refresh function or the events item within the fullcalendar configuration with an id param selected in the select box?
Thanks
Dont know if this is the “cool” way but it is working now with this solution:
So the calendar is loading with the new src and later its removed