jqgrid Click on the row list to select, click on the previous check box to select multiple

Set the following two properties:

multiselect: true,

multiboxonly: true,


If you want to click the row not to select, check the checkbox to select it, just override the beforeSelectRow method:

example:

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');

                }

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324648914&siteId=291194637