jquery Fullcalendar : dynamic events function asp.net mvc
Posted
by Eran
on Stack Overflow
See other posts from Stack Overflow
or by Eran
Published on 2010-05-31T20:41:39Z
Indexed on
2010/05/31
20:53 UTC
Read the original article
Hit count: 606
Hi,
I'm integrating Fullcalendar into my app. Consider a manager interface where he can select an employee and then view this employee's calendar. Now basically I'm using the following jquery code in my view:
<script type="text/javascript">
$(document).ready(function() {
$("#calendar").fullCalendar({
defaultView: 'agendaWeek',
isRTL: true,
axisFormat: 'HH:mm',
editable: true,
events: "/Scheduler/CalendarData"
});
});
</script>
Now I would like to have the controller function assigned to the events to retrieve the specific user selected by the manager:
events: "/Scheduler/CalendarData/<current_user_name>
Is there any way to retrieve the selected employee user name from the view (or rather pass it to the view from the controler) and then pass it onto the bound events function?
I hope I was clear enough...
Thanks in Advance, Eran
© Stack Overflow or respective owner