Having trouble implementing a date picker in angularjs and bootstrap due to the following issues:
- The initial date is not set
- When trying to open one date picker, all date pickers open
Below is my code snippet: http://plnkr.co/edit/elrOTfEOMmUkPYGmKTdW?p=preview
$scope.dateOptions = {
maxDate: new Date(2020, 5, 22),
minDate: new Date(1970,1,1),
startingDay: 1
};
function disabled(data) {
return true
}
$scope.open1 = function() {
$scope.popup1.opened = true;
};
$scope.formats = ['dd-MMM-yyyy', 'yyyy/MM/dd', 'dd.MM.yyyy', 'shortDate'];
$scope.format = $scope.formats[0];
$scope.popup1 = {
opened: false
};
Why do all date pickers open when only one is clicked? Image for reference below.