Use Current Culture Default Date Format as Parse Format
The default behavior of the DateTimePicker widget is to treat a value with no time part as invalid unless the corresponding format is provided in the parseFormats
option.
The following example demonstrates how to add the default short date format of the current culture to the parseFormats
array, so that when the time portion is removed from the DateTimePicker input, the value is still parsed as a valid date.
<script src="https://kendo.cdn.telerik.com/2016.3.1118/js/cultures/kendo.culture.bg-BG.min.js"></script>
<input id="datetimepicker" />
<script>
kendo.culture('bg-BG');
$("#datetimepicker").kendoDateTimePicker({
parseFormats: [kendo.culture().calendar.patterns['d']],
change: function(e){
console.log(this.value());
}
});
</script>