我想为日期选择器设置一个自定义的minDate。 我从输入中获得了自定义日期值:
var currentScheduledDate = jQuery("#scheduled_at").val();
我想将日期选择器设置为自定义日期+ 3天开始
这些是我的参数:
{
closeText: "Schließen",
prevText: "<Zurück",
nextText: "Vor>",
currentText: "Heute",
monthNames: [ "Januar","Februar","März","April","Mai","Juni",
"Juli","August","September","Oktober","November","Dezember" ],
monthNamesShort: [ "Jan","Feb","Mär","Apr","Mai","Jun",
"Jul","Aug","Sep","Okt","Nov","Dez" ],
dayNames: [ "Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag" ],
dayNamesShort: [ "So","Mo","Di","Mi","Do","Fr","Sa" ],
dayNamesMin: [ "So","Mo","Di","Mi","Do","Fr","Sa" ],
weekHeader: "KW",
isRTL: false,
showMonthAfterYear: false,
yearSuffix: "",
minDate: currentScheduledDate.getDate()+3,
maxDate: "+3M" ,
dateFormat : "dd-mm-yy",
beforeShowDay: jQuery.datepicker.noWeekends,
firstDay: 1
}
显然这不起作用:
minDate: currentScheduledDate.getDate()+3,
任何想法如何设置?谢谢