【发布时间】:2025-11-25 03:00:02
【问题描述】:
我处于这种情况,我想从 XML 文件加载事件,我正在使用以下代码:
events: function(start, end, callback) {
$.ajax({
url: '/contracts/'+contract_id+'.xml',
dataType: 'xml',
data: {
// our hypothetical feed requires UNIX timestamps
start: Math.round(start.getTime() / 1000),
end: Math.round(end.getTime() / 1000)
},
success: function(doc) {
var events = [];
$(doc).find('contract').each(function() {
events.push({
title: $(this).attr('week-mon-hours'),
start: $(this).attr('week-mon-hours') // will be parsed
});
});
callback(events);
}
});
},
在 XML 文件中,我有一个每周小时模式,我想将每周重复的模式插入到日历中。 我该怎么做?
【问题讨论】:
标签: xml fullcalendar init