Open felixwahner opened 10 years ago
I can confirm this. Setting startDate or endDate fails if it's using custom format. E.g below code has no effect on start or end_date
$('.datepicker').datepicker({
startDate: '20141015',
endDate: '20141030',
language: "de",
autoclose: true,
format: "yyyymmdd"
});
I can also confirm this. I tried to create a Year picker but was unable to limit the date range. I was able to get it to work by formatting my dates differently though.
Working example:
$('#year').datepicker({
startDate: "-35y",
endDate: "-1d",
minViewMode: 2,
format: 'yyyy'
});
Failing Example:
$('#year').datepicker({
startDate: "01/01/1990",
endDate: "01/01/2015",
minViewMode: 2,
format: 'yyyy'
});
Just keeping this alive as exactly the same problem. When Donald Trump conquers us all this will not be an issue; in the mean time, it's not great.
I'm currently trying to update this datepicker:
...which is initialized like this:
With this code...
...where startDate is a dynamic Date which is updated when selecting some options in a dropdown. Sadly this doesn't work as expected.
When I'm doing a "console.log(data[option])" in the $.fn.datepicker at line 1379 checking if the method setStartDate exists it returns undefined. Am I mistaking or is this a bug?