mirror of
https://github.com/xdan/datetimepicker.git
synced 2024-11-18 06:24:22 +00:00
Merge pull request #307 from SpoonNZ/patch-1
Allow maxDate in past or minDate in future
This commit is contained in:
commit
d070799dc8
@ -1030,11 +1030,11 @@
|
||||
timeboxparent.xdsoftScroller('hide');
|
||||
}
|
||||
|
||||
if (options.minDate && /^-(.*)$/.test(options.minDate)) {
|
||||
if (options.minDate && /^[\+\-](.*)$/.test(options.minDate)) {
|
||||
options.minDate = _xdsoft_datetime.strToDateTime(options.minDate).dateFormat(options.formatDate);
|
||||
}
|
||||
|
||||
if (options.maxDate && /^\+(.*)$/.test(options.maxDate)) {
|
||||
if (options.maxDate && /^[\+\-](.*)$/.test(options.maxDate)) {
|
||||
options.maxDate = _xdsoft_datetime.strToDateTime(options.maxDate).dateFormat(options.formatDate);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user