Search code examples
angularkendo-uidatepickertelerikkendo-ui-angular2

Zero number is always omitted in day section of Kendo-datepicker


I am trying to input the following date:

5/01/2017

But the first zero of days is always omitted by kendo-date-picker and my date becomes the following:

5/12/17

HTML:

        <kendo-datepicker
            [min]="min"
            [max]="max"
            [(ngModel)]="value"
            #dateModel="ngModel"
        ></kendo-datepicker>

What I can do to not omit zero in days section to input days with zero?

This behavior can be seen if you see DatePicker overview.


Solution

  • This is a known issue that is addressed in the 1.4.1 release of the @progress/kendo-angular-dateinputs. More details can be found in the corresponding issue:

    https://github.com/telerik/kendo-angular/issues/910

    The site is still using 1.3.1, which has the described issue. Once the new release is used,

    map: {
      ...,
      "@progress/kendo-angular-dateinputs": "https://unpkg.com/@progress/kendo-angular-dateinputs@1.4.1"
    },
    

    the component behaves as expected.

    http://plnkr.co/edit/HonarK6ICLxhs221YHiY?p=preview