mirror of
https://github.com/frappe/air-datepicker.git
synced 2026-01-14 02:49:13 +08:00
fixed min max dates handling, closes #123
This commit is contained in:
parent
28c56d2cf4
commit
ec46ba154e
4
dist/js/datepicker.js
vendored
4
dist/js/datepicker.js
vendored
@ -1895,10 +1895,10 @@
|
||||
|
||||
switch (this.d.view) {
|
||||
case 'days':
|
||||
if (!this.d._isInRange(new Date(y, m-1, d), 'month')) {
|
||||
if (!this.d._isInRange(new Date(y, m-1, 1), 'month')) {
|
||||
this._disableNav('prev')
|
||||
}
|
||||
if (!this.d._isInRange(new Date(y, m+1, d), 'month')) {
|
||||
if (!this.d._isInRange(new Date(y, m+1, 1), 'month')) {
|
||||
this._disableNav('next')
|
||||
}
|
||||
break;
|
||||
|
||||
2
dist/js/datepicker.min.js
vendored
2
dist/js/datepicker.min.js
vendored
File diff suppressed because one or more lines are too long
@ -89,10 +89,10 @@
|
||||
|
||||
switch (this.d.view) {
|
||||
case 'days':
|
||||
if (!this.d._isInRange(new Date(y, m-1, d), 'month')) {
|
||||
if (!this.d._isInRange(new Date(y, m-1, 1), 'month')) {
|
||||
this._disableNav('prev')
|
||||
}
|
||||
if (!this.d._isInRange(new Date(y, m+1, d), 'month')) {
|
||||
if (!this.d._isInRange(new Date(y, m+1, 1), 'month')) {
|
||||
this._disableNav('next')
|
||||
}
|
||||
break;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user