Tips related to checkbars
This is an example of specifying the row color when the check bar is checked.
gridView.setRowStyleCallback(function(grid, item, fixed) {
if (item.checked) {
return 'orange-color'
}
})This is an example of retrieving information about rows checked in the check bar.
var rowData = [];
var rows = gridView.getCheckedRows();
for (var i in rows) {
var data = dataProvider.getJsonRow(rows[i]);
rowDatas.push(data);
}
alert(JSON.stringify(rowDatas));This is an example of deleting the rows checked in the check bar.
The example below only changes the row status to deleted, but if you actually want it to be deleted from the grid, you can set it as follows.
dataProvider.softDeleting = true; //Get checked rows
var rows = gridView.getCheckedRows();
//delete row
dataProvider.removeRows(rows);
//uncheck
gridView.checkRows(rows, false);