前7天后7天
<el-date-picker v-model="value1" type="date" :picker-options="pickerOptions" placeholder="选择日期"> </el-date-picker> data:{ value1:"", pickerOptions: { //禁用的时间 ele disabledDate(time) { return time.getTime() < Date.now() - 3600 * 1000 * 24 * 7 || time.getTime() > Date.now() + 3600 * 1000 * 24 * 7; } }, },