1
초보자입니다 ... Jendered와 검도 그리드를 사용하고 있습니다.검도 그리드에서 현재 정렬 필드를 얻는 방법은 무엇입니까?
나는 kendo-gird에서 현재 정렬 된 필드를 가져오고 싶습니다.
찾았습니다. console.log (grid.dataSource._sort [0] .dir); console.log (grid.dataSource._sort [0] .field);
대체 방법을 찾을 수 있습니까?
이것은 내 코드입니다.
var dataSource = new kendo.data.DataSource({
transport : {
read : {
type : 'post',
dataType : 'json',
contentType : 'application/json;charset=UTF-8',
url : cst.contextPath() + "/watcher/kendoPagination_statsErrorHistoryRetrieveQry.htm",
data : param
},
parameterMap: function (data, opperation) {
return JSON.stringify(data);
}
},
schema : {
data : function(data) {
return data;
},
total : function(response) {
return response.length > 0 ? response[0].TOTAL_COUNT : 0;
}
},
pageSize : cst.countPerPage(),
serverPaging : true,
serverSorting : true
});
var columns = kendoGridColumns();
$("#grid")
.kendoGrid({
dataSource : dataSource,
sortable : {
mode : 'multiple',
allowUnsort : true
},
columns : columns.error()
selectable : 'row',
scrollable : true,
resizable : true,
}));
어떻게 현재 정렬 된 필드 이름을 얻을 수 있습니까?