当前使用 fullcalendar.io
在文档中,它有 calendar.fullCalendar('refetchEvents') 可以从服务器重新获取所有事件。
简而言之,我希望 calendar.fullCalendar('refetchEvents') 请求完成并向我发送回调以告知我。我希望在继续执行某些任务之前下载所有事件。
我怎样才能做到这一点?
最佳答案
通过在成功的 http post 后执行重新获取事件来解决此问题,如下所示
Service.insert(event).
success(function (data, status, headers, config) {
calendar.fullCalendar('refetchEvents');
}).
error(function(data, status, headers, config) {
alert('error');
});
关于jquery - 全日历重新获取事件回调,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27622257/