멀티셀렉트( multiselect : true) 옵션을 사용했을 경우
오직 체크박스에 대해서만 onSelectRow 이벤트를 적용하려면 다음과 같은 코드를 이용한다.
beforeSelectRow: function (rowid, e) {
var $myGrid = $(this),
i = $.jgrid.getCellIndex($(e.target).closest('td')[0]),
cm = $myGrid.jqGrid('getGridParam', 'colModel');
return (cm[i].name === 'cb');
}
참고 :
1. http://stackoverflow.com/questions/7627512/jqgrid-multiselect-limit-the-selection-of-the-row-only-using-the-checkbox
2. http://www.ok-soft-gmbh.com/jqGrid/SimpleLocalGridWithMultiselection.htm
'etc > jqGrid' 카테고리의 다른 글
[작성중][jqGrid] Treegrid 샘플 - ajax , adjacency (0) | 2014.09.24 |
---|---|
[jqGrid] 그리드를 생성 후 xmlstring 데이터를 동적으로 로드하는 방법 (0) | 2014.08.22 |
[jqGrid cookbook] 1. jqGrid (0) | 2014.01.15 |