Skip to content

Commit

Permalink
fix(calendar(js)): don't modify time when computing dates interval
Browse files Browse the repository at this point in the history
Fixes #4861
  • Loading branch information
cgx committed Oct 30, 2019
1 parent d1e2418 commit 487bbf7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions UI/WebServerResources/js/Common/utils.js
Expand Up @@ -284,10 +284,10 @@ Date.prototype.daysUpTo = function(otherDate) {
for (var i = 0; i < nbrDays; i++) {
var newDate = new Date();
newDate.setTime(day1 + (i * DAY_SECS));
newDate.setHours(0);
newDate.setMinutes(0);
newDate.setSeconds(0);
newDate.setMilliseconds(0);
newDate.setHours(this.getHours());
newDate.setMinutes(this.getMinutes());
newDate.setSeconds(this.getSeconds());
newDate.setMilliseconds(this.getMilliseconds());
days.push(newDate);
}

Expand Down

0 comments on commit 487bbf7

Please sign in to comment.