Hello everyone,
I’m hoping someone here can help me with the following: -
Currently, I have the following script for my delivery-date datepicker snippet where I have excluded Sundays.
I would like to add the following conditions: -
- Exclude specific dates (i.e. 16/04/21, etc.)
- Disable next business day selection by customers AFTER 12pm.
For point #2, I have the following code but am unsure of where to include it in the above: -
$("#date" ).datepicker({
minDate: +1,
beforeShow : function(){
var dateTime = new Date();
var hour = dateTime.getHours();
if(hour >= 12){
$(this).datepicker( "option", "minDate", "+2" );
}
}
});
Please let me know, thank you!