Make sure listview header gets a date

This commit is contained in:
nathangray 2016-07-26 09:51:36 -06:00
parent 28cddb8e64
commit 6a5003fee7

View File

@ -3998,11 +3998,11 @@ jQuery.extend(app.classes.calendar,{
listview: app.classes.calendar.prototype.View.extend({
header: function(state)
{
var startDate = new Date(state.first);
var startDate = new Date(state.first || state.date);
startDate = new Date(startDate.valueOf() + startDate.getTimezoneOffset() * 60 * 1000);
var start_check = ''+startDate.getFullYear() + startDate.getMonth() + startDate.getDate();
var endDate = new Date(state.last);
var endDate = new Date(state.last || state.date);
endDate = new Date(endDate.valueOf() + endDate.getTimezoneOffset() * 60 * 1000);
var end_check = ''+endDate.getFullYear() + endDate.getMonth() + endDate.getDate();
return app.calendar.View._owner(state) +