|
|
@ -684,11 +684,6 @@ Messages.calendar_allDay = "All day";
|
|
|
|
|
|
|
|
|
|
|
|
var startDate = event.start._date;
|
|
|
|
var startDate = event.start._date;
|
|
|
|
var endDate = event.end._date;
|
|
|
|
var endDate = event.end._date;
|
|
|
|
var startDay, endDay;
|
|
|
|
|
|
|
|
if (event.isAllDay) {
|
|
|
|
|
|
|
|
startDay = startDate.getFullYear() + '-' + (startDate.getMonth()+1) + '-' + startDate.getDate();
|
|
|
|
|
|
|
|
endDay = endDate.getFullYear() + '-' + (endDate.getMonth()+1) + '-' + endDate.getDate();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var schedule = {
|
|
|
|
var schedule = {
|
|
|
|
id: Util.uid(),
|
|
|
|
id: Util.uid(),
|
|
|
@ -697,13 +692,10 @@ Messages.calendar_allDay = "All day";
|
|
|
|
category: "time",
|
|
|
|
category: "time",
|
|
|
|
location: Util.fixHTML(event.location),
|
|
|
|
location: Util.fixHTML(event.location),
|
|
|
|
start: +startDate,
|
|
|
|
start: +startDate,
|
|
|
|
startDay: startDay,
|
|
|
|
|
|
|
|
isAllDay: event.isAllDay,
|
|
|
|
isAllDay: event.isAllDay,
|
|
|
|
end: +endDate,
|
|
|
|
end: +endDate,
|
|
|
|
endDay: endDay
|
|
|
|
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
newEvent(schedule, function (err) {
|
|
|
|
newEvent(schedule, function (err) {
|
|
|
|
if (err) {
|
|
|
|
if (err) {
|
|
|
|
console.error(err);
|
|
|
|
console.error(err);
|
|
|
|