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

Sharing the grids DataSource with the Filterable Datasource

1 Answer 30 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Toffer
Top achievements
Rank 2
Toffer asked on 25 Apr 2016, 04:44 PM

Hey all...

I'm trying to figure out something that's either probably pathetically simple and is for some reason just eluding me or it's not possible and I've pulled all this hair out for nothing...

 

I know that when you just add the .Filterable property onto a column it adds the nifty little filter onto it that's pretty awesome out of box.  The one small over-site IMHO is that it is not a distinct list and is not sorted.  I haven't seen any options to enable these sort of things...and I've been reading posts from others looking for this sort of functionality...and they've been told it's not there yet.

So what I want to do is to pass the Grid's DataSource into a controller action as an argument using the .Data off the .Read in the .Filterable's .DataSource...then inside that controller action I'd use a Linq query to return a sorted distinct list.

The reason I want to do that is I want to avoid having to make another call across the wire to get all those record when I already had them in the grid...it should be more performant IMHO.  :)

So is this possible and I'm just missing it?  I'm using Razor so I'd appreciate any examples to be in that format, but I'll take any help in any format I can get.  :)

1 Answer, 1 is accepted

Sort by
0
Kostadin
Telerik team
answered on 27 Apr 2016, 11:28 AM
Hi Toffer,

Thank you for contacting us.

As far as I understand you are trying to sort the values of the multiple checkbox filter menu. If that is your requirement I would recommend you to examine the following how to article. Generally you need to hook filterMenuInit event handler and sort the data.
Otherwise I would appreciate if you can elaborate a little bit more on your scenario.

I am looking forward to your reply.

Regards,
Kostadin
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
Toffer
Top achievements
Rank 2
Answers by
Kostadin
Telerik team
Share this question
or