如何使用 jQuery 数据属性获取 Kendo UI 网格 orderBy 属性?
例如在 telerik UI 中,我可以做类似的事情
jQuery("#name").data("tGrid").orderBy
这给了我所需的结果,即网格当前排序所依据的列。我在 Kendo 中找不到相应的属性
.
同样,我也需要 groupBy 和 filterBy 属性。
最佳答案
要获取分组依据、筛选和排序属性,以下是方法。引用 Kendo Grid API documentation
var grid = $('#GridId').data('kendoGrid');
var grouping = grid.dataSource.group();
var filtering = grid.dataSource.filter();
var sorting = grid.dataSource.sort();
//here, sorting[0] will give you the field for which, sorting is done
关于jquery - Kendo UI 如何使用 jQuery 获取网格属性?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17523210/