javascript - Disable kendogrid filter on particular column - Stack Overflow

I need to disable the Kendo filter option on particular column on click of a button. I gave a shot as m

I need to disable the Kendo filter option on particular column on click of a button. I gave a shot as mentioned in link Grid Custom Filter for Columns Not In Grid but it throws error since filterable is not defined. Please help.

function ButtonClick() {
var TestGridDetails = $("#TestGrid").data("kendoGrid");
TestGridDetails.columns[6].filterable(false);
}

I need to disable the Kendo filter option on particular column on click of a button. I gave a shot as mentioned in link Grid Custom Filter for Columns Not In Grid but it throws error since filterable is not defined. Please help.

function ButtonClick() {
var TestGridDetails = $("#TestGrid").data("kendoGrid");
TestGridDetails.columns[6].filterable(false);
}
Share Improve this question edited May 23, 2017 at 12:08 CommunityBot 11 silver badge asked Nov 28, 2014 at 9:09 InterstellarInterstellar 6742 gold badges13 silver badges30 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 3

It seems you can't just change one column value; you can change options globally with the setOptions method but you need to define all of the columns' details.

function ButtonClick() {
  var TestGridDetails = $("#TestGrid").data("kendoGrid"),
      columnsConfig = TestGridDetails.options.columns;
  columnsConfig[6].filterable = false;
  TestGridDetails.setOptions({columns: columnsConfig});
}

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745646262a4637990.html

相关推荐

  • javascript - Disable kendogrid filter on particular column - Stack Overflow

    I need to disable the Kendo filter option on particular column on click of a button. I gave a shot as m

    22天前
    40

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信