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

TreeList filterBy

2 Answers 77 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Matej
Top achievements
Rank 1
Veteran
Matej asked on 21 Jul 2020, 02:12 PM

Hi,

Is the filterBy from TreeList working with a CompositeFilterDescriptor? Because in the doc there is "descriptors FilterDescriptor[] | CompositeFilterDescriptor[]"  https://www.telerik.com/kendo-react-ui/components/treelist/api/filterBy/ but I was not able to make it work https://stackblitz.com/edit/react-dyav5s?file=app/main.jsx . If there is no support for CompositeFilterDescriptor do you have available some function to convert the CompositeFilterDescriptor to FilterDescriptor?

2 Answers, 1 is accepted

Sort by
0
Accepted
Stefan
Telerik team
answered on 22 Jul 2020, 06:10 AM

Hello, Matej,

The filterBy is working with CompositeFilterDescriptor. It expects an array of CompositeFilterDescriptors `CompositeFilterDescriptor[]`.

When I made the filter in the example an array (it was an object originally), it was working as expected:

https://stackblitz.com/edit/react-dyav5s-fzz5rx?file=app/main.jsx

Still, please have in mind that this will not populate the filter row as the filter row can only work with filter descriptors as it has only one level of filtering:

https://www.telerik.com/kendo-react-ui/components/treelist/api/TreeListProps/#toc-filter

Regards,
Stefan
Progress Telerik

0
Matej
Top achievements
Rank 1
Veteran
answered on 22 Jul 2020, 06:40 AM
sorry, my bad. Thank you!
Tags
General Discussions
Asked by
Matej
Top achievements
Rank 1
Veteran
Answers by
Stefan
Telerik team
Matej
Top achievements
Rank 1
Veteran
Share this question
or