<div class="c-datepicker-date-editor c-datepicker-single-editor J-yearPicker-single"> <input type="text" name="jobStartYear" class="c-datepicker-data-input" placeholder="请选择起始从业年份" autocomplete="off"> </div> $('.J-yearPicker-single').datePicker({ format: 'YYYY', max: '2019' });
这样写的,但是年份的最大值没得用