в ASP.NET MVC View:
$('#calendar').fullCalendar({
theme: true,
header: {
left: 'prev,next today',
center: 'title',
right: 'month,agendaWeek,agendaDay'
},
events: "/Calendar/GetEvents/"});
Контроллер:
public JsonResult GetEvents()
{
List<DAL.VwMeeting> allMeeting = meetingRepository.GetAll();
var eventList = from e in allMeeting
select new
{
url=(e.MeetingOccurID).ToString(),
title = e.MeetingTitle,
start = ConvertToUnixTimestamp((DateTime)e.MeetingOccurStartDate),
end = ConvertToUnixTimestamp((DateTime)e.MeetingOccurEndTime),
allDay = false
};
return Json(eventList.ToArray());
}
или вы можете использовать:
$('#calendar').fullCalendar('refetchEvents');
после каждого дескриптора события