Closed eltigre4jc closed 10 years ago
try this as a workaround:
var to = $('#To').val();
$('#To').datepicker('option', 'minDate', $('#From').datetimepicker('getDate')).val(to);
doesn't work... it seems that this is a serious bug with minDate and maxDate
I also ran into this and it seems that you have to set minDateTime and maxDateTime. So in your case it would be:
$('#To' ).datepicker('option', 'minDateTime', $('#From').datetimepicker('getDate'));
But either way there is some inconsistency, because when you set minDate when initializing the datetimepicker the time is also set (which led me to the conclusion that minDate equals minDateTime, therefore the confusion)
It sounds like this original issue has been fixed in the dev branch, so I am closing this issue. Please reopen if it is not.
Hi! I saw that are more issues more or less related to this one. My scenario is like this: 2 vb net controls (DateFrom and DateTo) with a textBox and datepickers. 1 option: ShowTime. If set to false, I use datepicker, else i use datetimepicker
I set the date of the first control to be the minDate for the second through a javascript
$('#To' ).datepicker('option', 'minDate', $('#From').datetimepicker('getDate'));
When I open the second control with datetimepicker, only the date, and NOT the time is set..
I tried to look in the plugin, the follow with the debugger, but I cannot understand where do I have to change and what do I have to change to make it work. Basically, half of the action is done, it remains the part with the time
Maybe we can have a fix for this or at least a workaround... Please help. Thank you :)