mirror of
https://github.com/xdan/datetimepicker.git
synced 2024-11-18 06:24:22 +00:00
commit
a80fc2d845
@ -1402,9 +1402,11 @@
|
||||
h = parseInt(now.getHours(), 10);
|
||||
now.setMinutes(m);
|
||||
m = parseInt(now.getMinutes(), 10);
|
||||
|
||||
var optionDateTime = new Date(_xdsoft_datetime.currentTime)
|
||||
optionDateTime.setHours(h);
|
||||
optionDateTime.setMinutes(m);
|
||||
classes = [];
|
||||
if ((options.maxTime !== false && _xdsoft_datetime.strtotime(options.maxTime).getTime() < now.getTime()) || (options.minTime !== false && _xdsoft_datetime.strtotime(options.minTime).getTime() > now.getTime())) {
|
||||
if((options.minDateTime !== false && options.minDateTime > optionDateTime) || (options.maxTime !== false && _xdsoft_datetime.strtotime(options.maxTime).getTime() < now.getTime()) || (options.minTime !== false && _xdsoft_datetime.strtotime(options.minTime).getTime() > now.getTime())) {
|
||||
classes.push('xdsoft_disabled');
|
||||
}
|
||||
if ((options.initTime || options.defaultSelect || datetimepicker.data('changed')) && parseInt(_xdsoft_datetime.currentTime.getHours(), 10) === parseInt(h, 10) && (options.step > 59 || Math[options.roundTime](_xdsoft_datetime.currentTime.getMinutes() / options.step) * options.step === parseInt(m, 10))) {
|
||||
|
Loading…
Reference in New Issue
Block a user