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

Using filter in data-bind of kendoGrid

1 Answer 342 Views
Grid
This is a migrated thread and some comments may be shown as answers.
J
Top achievements
Rank 1
J asked on 21 Apr 2014, 07:39 PM
I have the following values in my in my razor div tag:

 

 

<div class="countdownKendoGrid" data-bind="kendoGrid: { data: $parent.RandomList, rowTemplate: ​'rl-row-template',​columns: [{ field: 'COL1', title: 'COL1', width: '50%' }, { field: 'COL2', title: 'COL2', width: '50%' }], filter: [{ field: ​'COL1', operator: 'eq', value: 'AB1234' }]}​"></div>

My questions, since I'm rather new at this, are:
1). Why would just the row where COL1 equals to AB1234 not be the only one that appears?
2).  could I substitute "value: 'AB1234'" to be a property in my ViewModel?  ie: value: $parent.MyBindableValue

J

 

​​​​​​​​​​​​​​​

 

1 Answer, 1 is accepted

Sort by
0
Alexander Valchev
Telerik team
answered on 23 Apr 2014, 04:06 PM
Hello,

Regarding your questions:

1. The filter expression should be set at dataSource level. Filter property is part of the DataSource object, not the Grid itself.
2. It looks like that you are using kendo-knockout. Is my assumption correct? The Knockout-Kendo library is part of the Kendo UI Labs projects. As such, these projects are not officially supported by the Kendo UI team. Any support requests (via tickets or Forum posts) should go to either StackOverflow, or to the Issues list for that project.


Regards,
Alexander Valchev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Grid
Asked by
J
Top achievements
Rank 1
Answers by
Alexander Valchev
Telerik team
Share this question
or