Skip to content

Commit

Permalink
fix(datepiker): dynamic min-mode and max-mode fix
Browse files Browse the repository at this point in the history
- Reapply changes that was made in 0.3.13 to make min-mode and max-mode work correctly in popup

Closes angular-ui#5240
  • Loading branch information
luber committed Jan 15, 2016
1 parent b76e98e commit 04e76cd
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions src/datepicker/datepicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -656,16 +656,7 @@ function(scope, element, attrs, $compile, $parse, $document, $rootScope, $positi
});
}

angular.forEach(['minMode', 'maxMode'], function(key) {
if (attrs[key]) {
scope.$parent.$watch(function() { return attrs[key]; }, function(value) {
scope.watchData[key] = value;
});
datepickerEl.attr(cameltoDash(key), 'watchData.' + key);
}
});

angular.forEach(['datepickerMode', 'shortcutPropagation'], function(key) {
angular.forEach(['minMode', 'maxMode', 'datepickerMode', 'shortcutPropagation'], function(key) {
if (attrs[key]) {
var getAttribute = $parse(attrs[key]);
var propConfig = {
Expand Down

0 comments on commit 04e76cd

Please sign in to comment.