Fix drag and drop across some months could change event to the wrong (± 1) month - now works with any date format

This commit is contained in:
Nathan Gray 2016-04-04 22:06:01 +00:00
parent e79b418f04
commit 211d3a5438

View File

@ -412,7 +412,11 @@ var et2_calendar_timegrid = (function(){ "use strict"; return et2_calendar_view.
}
if(event_widget)
{
event_widget._parent.date_helper.set_value(drop_date.substring(0,4)+'-'+drop_date.substring(4,6)+'-'+drop_date.substring(6,8));
// Send full string to avoid rollover between months using set_month()
event_widget._parent.date_helper.set_value(
drop_date.substring(0,4)+'-'+drop_date.substring(4,6)+'-'+drop_date.substring(6,8)+
'T00:00:00Z'
);
// Make sure whole day events stay as whole day events by ignoring drop time