Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

Commit

Permalink
fix(datepickerPopup): apply timezone conversion
Browse files Browse the repository at this point in the history
- Apply timezone conversion to selecting today

Closes #6173
Fixes #6147
  • Loading branch information
wesleycho committed Aug 18, 2016
1 parent f798a47 commit f147d22
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/datepickerPopup/popup.js
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,8 @@ function($scope, $element, $attrs, $compile, $log, $parse, $window, $document, $
date = new Date($scope.date);
date.setFullYear(today.getFullYear(), today.getMonth(), today.getDate());
} else {
date = new Date(today.setHours(0, 0, 0, 0));
date = dateParser.fromTimezone(today, ngModelOptions.timezone);
date.setHours(0, 0, 0, 0);
}
}
$scope.dateSelection(date);
Expand Down

0 comments on commit f147d22

Please sign in to comment.