This is a migrated thread and some comments may be shown as answers.

Kendo Grid Column Date Range Filter - JS

1 Answer 423 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Ben
Top achievements
Rank 1
Ben asked on 27 Apr 2016, 09:19 PM

Hello, I'm trying to create a date range picker for a column in a kendo grid that will also use the datepicker UI. Running into a lot of issues here.

I have a JSON file that I am using as a datasource. I'm converting each date string into a date object.

Sorting seems to work on this column, but I'm having issues with any kind of gte/lte operators, they don't seem to work at all.

This is the config I have for the specific column, I'm not very familiar with Kendo and haven't found a forum that uses Kendo grid with pure javascript that utilizes a date range picker on just one column. Any help would be much appreciated, thanks!

{

                         field: '["Status Date"]',

                        title: "Status Date",
                        type: "date",
                        format: "{0: MM/dd/yyyy}",
                        filterable: {
                            operators: {
                                string: {
                                    lt: "Is before",
                                    gt: "Is after"
                                }
                            },
                            ui: function(element) {
                                element.kendoDatePicker({
                                    format: "{0: MM/dd/yyyy}",
                                });
                            },
                            extra: true,
                             messages: {
                                 "info": "Show items between dates:"
                             }
                        }
                    }

1 Answer, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 29 Apr 2016, 10:33 AM
Hello,

As far as I understand your scenario, it seems similar to the one described in the following forum thread. In the last post, my colleague provides a live sample, which shows how you could filter a range with 2 pickers.

I hope this implementation will help you to achieve the desired behavior. If you have any questions on the implementation, I would suggest you to address them in the other thread, in order to keep them in the same context.

Regards,
Dimitar
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Grid
Asked by
Ben
Top achievements
Rank 1
Answers by
Dimitar
Telerik team
Share this question
or