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

grid helper column level filter/sort

1 Answer 117 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Adam
Top achievements
Rank 1
Adam asked on 30 Jul 2012, 03:43 PM
I am having a problem getting column level filtering and sorting to work when using the html helper.

I assumed the following would be a column level override, yet this doesn't disable either sorting or filtering.
columns.Bound(o => o.Id).Sortable(false).Filterable(false)

If I don't add the filterable method to the grid then filters don't show for any columns.
//.Filterable()

Yet writing the Javascript by hand it seems setting the column level works. It seems like the column level isn't rendering the correct markup through the helper. Is there a way to access an existing grid and change these options I want to try to avoid rewriting the grids in Javascript which would not only be a pain but defeat the usefulness of the html helper.

I have tried accessing the current Javascript value for a given column to no prevail

var grid = $("#grid").data("kendoGrid");
document.write(grid.columns[1].filterable());
grid.columns[1].filterable(false);
grid.refresh();

1 Answer, 1 is accepted

Sort by
0
Adam
Top achievements
Rank 1
answered on 13 Aug 2012, 03:44 PM
No longer an issue. This seems to be fixed in the latest version
Tags
Grid
Asked by
Adam
Top achievements
Rank 1
Answers by
Adam
Top achievements
Rank 1
Share this question
or