0
我想将Today日期绑定到模型和Kendo UI Datepicker并保持它们同步,但它不起作用...我的DatePicker从不在控件上显示模型值。AngularJS KendoUI DatePicker Model not binding
这里是我的代码角:
vm.startDateOptions = {
parseFormats: ["YYYY-MM-DD"]
};
vm.searchInfos = {
startDate: moment(new Date()).format('YYYY-M-D')
// Giving 2015-10-14 for today
}
HTML:
<input onkeydown="return false;" id="start" kendo-date-picker
k-options="vm.startDateOptions"
k-ng-model="vm.searchInfos.start"
style="width: 100%;" />
也许你在这里犯了一个错误'k-ng-model =“vm.searchInfos.start”'。 您应该使用'startDate'而不是'start'。 –
arg ....这么多时间试图了解这样的错误的问题.... thx – Vince