我的代码片段
$('#calendar').fullCalendar({
allDaySlot: false,
header: {
left: 'today prev next',
center: 'title',
right: 'agendaWeek,agendaDay'
},
axisFormat: 'HH:mm',
timeFormat: {agenda: 'HH:mm{ - HH:mm}'},
defaultView: 'agendaWeek',
editable: false,
minTime: '8:30am',
maxTime: '10:00pm',
weekends: false,
eventRender: function(event, element) {
// some code
},
eventClick: function(calEvent, jsEvent, view) {
//some code
},
dayClick: function(date, jsEvent, calEvent) {
//some code
}
此外,还有 ajax 调用来刷新日历和显示事件。我想在页面加载时禁用单击日历事件,即在 ajax 请求正在进行时。