<van-datetime-pickertype="datetime"title="选择开始时间":min-date="minDate"/>
1.当前时间
this.minDate = new Date();
2.当前时间往后推24小时
this.minDate = new Date(Date.now() + 24 * 60 * 60 * 1000);
3.当前日期往后推一天 注:(2和3效果相同)
var currentDate = new Date();this.minDate = this.addOneDayToDate(currentDate);addOneDayToDate(date) {date.setDate(date.getDate() + 1);return date;},
4.当前日期往后推一天 的零点
this.minDate = this.addOneDayToDate();
addOneDayToDate() {const now = new Date();now.setDate(now.getDate() + 1); // 当前日期加一now.setHours(0, 0, 0, 0); // 时分秒和毫秒都设置为0return now;},