Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

jqGrid multiselect gives only ids when top checkbox has been checked?

Tags:

jquery

jqgrid

I have a jqGrid with multiselect:true. In a click event of a button I try to retrieve the ids like:

var ids = $('#myGrid').jqGrid('getGridParam', 'selarrrow');

However I only get ids to be filled with something if I select the top checkbox in the header. If I do not select that one in the header but select several checkboxes in the column ids has no selected ids in it. How to overcome this?

sellarrrow is according to this example written correctly: http://www.trirand.com/blog/jqgrid/jqgrid.html, select Advanced, Multiselect example.

like image 346
Nyla Pareska Avatar asked Dec 07 '25 10:12

Nyla Pareska


1 Answers

Turned out to be a defaulting setup where this was set:

beforeSelectRow: function(rowid, e) { return false; },

Setting that to true gave me back the power.

like image 55
Nyla Pareska Avatar answered Dec 09 '25 23:12

Nyla Pareska



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!