Unplanned
Last Updated: 27 Sep 2024 09:58 by ADMIN
Andrew
Created on: 20 Sep 2024 14:06
Category: Kendo UI for jQuery
Type: Feature Request
0
Filter and Grid Cell Editing Date Format

I am running into an issue with allowing copy/paste of dates into the filter and cell input fields. Currently, the date fields have validation to support MM/dd/yyyy, and users of the app may be trying to copy dates in that are MM/dd/yy. I would expect Kendo to auto format the date to MM/dd/yyyy after the paste happens, or at least allow support for that, but it doesn't seem to happen.

In the cell, when putting in MM/dd/yy, a validation message appears saying the date is invalid, and there doesn't appear to be a way to override that. In the filter, when putting in MM/dd/yy and submitting the filter, it doesn't stick and completely ignores the date put in.

Steps to reproduce (filter):

  1. Copy a date formatted as MM/dd/yy
  2. Paste it into a date column filter
  3. Attempt to apply filter
  4. Notice that the filter is ignored

Steps to reproduce (cell edit):

  1. Copy a date formatted as MM/dd/yy
  2. Paste it into a cell datepicker field
  3. Notice the validation flags it as an invalid date
1 comment
ADMIN
Neli
Posted on: 27 Sep 2024 09:58

Hello Andrew,

As I have replied previously in the support thread regarding the same issue I am pasting my reply below as well as it could be helpful to the other users. 

You can set the format for the date column using the columns.format option:

- https://docs.telerik.com/kendo-ui/api/javascript/ui/grid/configuration/columns.format


Starting with the 2024 R3 release the Grid provides auto adjust feature in the DatePicker component. You can read more in the following link:

- https://docs.telerik.com/kendo-ui/controls/datepicker/auto-adjust

However, even if you try to enable the auto adjust in the DatePicker editor (as in the Dojo linked here) the date will be adjusted only when the user types a date, but not when pasting a value.

With the above said, I am changing the status of the feature request to 'Unplanned'. We will monitor the community interest in such a feature and based on it we will consider wether to add it for implementation in a future release. 

Regards,
Neli
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.