开发者

jquery fullcalendar : operation after data add

开发者 https://www.devze.com 2023-03-22 03:56 出处:网络
When we add a event to jquery full开发者_开发知识库calendar (in selectable mode)on click or selecting dates. How to read the added event in jquery ?EDIT - after your comment i think you must use the s

When we add a event to jquery full开发者_开发知识库calendar (in selectable mode)on click or selecting dates. How to read the added event in jquery ?


EDIT - after your comment i think you must use the select function:

select: function(start, end, allDay) {
    var title = prompt('Event Title:');
    if (title) {
        alert('start:'+start+' end: '+end);
        calendar.fullCalendar('renderEvent', {
            title: title,
            start: start,
            end: end,
            allDay: allDay
        }, true // make the event "stick"
        );
    }
    calendar.fullCalendar('unselect');
},

Look at the fiddle here, it alerts start and end date, but you also have access to tile and allDay parameters.http://jsfiddle.net/SYBsq/

0

精彩评论

暂无评论...
验证码 换一张
取 消