Avoid selection of invalid dates

This commit is contained in:
Björn Fromme
2019-12-28 17:30:03 +01:00
parent 03e26b255f
commit 4288ffee4f
@@ -107,6 +107,10 @@
if (this.from && this.to) { if (this.from && this.to) {
this.picker.setDate([ new Date(this.from), new Date(this.to) ]); this.picker.setDate([ new Date(this.from), new Date(this.to) ]);
} }
if (this.minDate && this.maxDate) {
this.picker.set('minDate', new Date(this.minDate));
this.picker.set('maxDate', new Date(this.maxDate));
}
}); });
EventBus.$on('filterSettingsReset', () => { EventBus.$on('filterSettingsReset', () => {
this.reset(); this.reset();