I am using asp.net mvc to list the events in the jquery full calendar. Below is the script i am using to list the events through json from mvc.
$('#calendar').fullCalendar({
theme: true,
editable: true,
disableDragging: true,
disableResizing: true,
header: {
left: 'prev,next today',
center: 'title',
right: 'month,basicWeek,basicDay'
},
events: function(start, end, callback) {
// do some asynchronous ajax
$.getJSON("/User/GetEvents/",
{
start: dateFormat(start.getTime()),
end: dateFormat(end.getTime())
},
function(result) {
// then, pass the CalEvent array to the callback
callback(result);
})
},
eventClick : function(event) {
editEventShow(event);
},
dayClick : function(dayDate){
addEventShow(dayDate, this);
}
});
But the above script not showing any events in the calendar. What am i doing wrong in the above script?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…