0
I have a calendar that works correctly that eliminates weekends, but I also wanted for example: now it is 11 hours so all previous times were disabled so it is not possible to select.
$(document).ready(function(e) {
$.datetimepicker.setLocale('pt-BR');
$("#hora").datetimepicker({
minDate: 0,
dayOfWeekStart: 1,
addSliderAccess: true,
sliderAccessArgs: {
touchonly: false
},
format: 'd/m/Y H:i',
allowTimes: [
'09:00', '09:30', '10:00',
'10:30', '11:00', '11:30',
'12:00', '12:30', '13:00', '13:30',
'14:00', '14:30', '15:00', '15:30', '16:00', '16:30',
'17:00', '17:30', '18:00'
],
beforeShowDay: function(date) {
var day = date.getDay();
return [(day != 0 && day != 6)];
}
You can help https://stackoverflow.com/questions/43860602/datetimepicker-cannot-select-minutes-less-current-minute-although-hour-is
– David
thanks David for the help ,but I found a solution
– f3107
could you put the solution you found in answer to that question? So if other users have a similar problem they were able to solve the problem.
– David
yes of course already this below
– f3107