Fix planner view got end date wrong when adding an event by clicking on a row.

This commit is contained in:
Nathan Gray 2015-11-16 17:07:56 +00:00
parent 98c18b04ec
commit 406c96defe

View File

@ -1843,7 +1843,7 @@ var et2_calendar_planner = et2_valueWidget.extend([et2_IDetachedDOM, et2_IResize
var row = $j(_ev.target).closest('.calendar_plannerRowWidget');
var data = row.length ? row[0].dataset : {};
this.egw().open(null, 'calendar', 'add', jQuery.extend({
start: date.toJSON(),
date: date.toJSON(),
hour: date.getUTCHours(),
minute: date.getUTCMinutes()
},data) , '_blank');
@ -1895,7 +1895,7 @@ var et2_calendar_planner = et2_valueWidget.extend([et2_IDetachedDOM, et2_IResize
// Default handler to open a new event at the selected time
// TODO: Determine date / time more accurately from position
this.egw().open(null, 'calendar', 'add', {
date: _ev.target.dataset.date || this.day_list[0],
date: _ev.target.dataset.date || this.options.start_date.toJSON(),
hour: _ev.target.dataset.hour || this.options.day_start,
minute: _ev.target.dataset.minute || 0
} , '_blank');