datagrid列:

{
field: 'n1', title: '创建', align: 'center', formatter: function (value, row, index)
var str = '';
if (row.childcount == 0) {
str = "<input type=checkbox value='" + row.id + "' id='cbSelSet' onclick='clickchk(this)'>";
}
return

复选框勾选事件:

var selSetList=[];

function clickchk(cb)
if (cb.checked) {
if ($.inArray(cb.value,selSetList) < 0) {
selSetList.push(cb.value);
}
} else {
selSetList.splice($.inArray(cb.value, selSetList), 1)
}
}