JqGrid: how to load all data when selecting all checkboxes?

I have large jqGrids with ~ 1000-2000 lines, but only 100 are loaded by default. I have multiselect set to true and use a virtual scroll, and when I click on the select all check box, only those that are already loaded are selected.

I told my users that as a workaround, they need to scroll down the page until all the lines have been loaded.
It works, but not very convenient.

I need a way to load a full grid when I click the Select All button. There is an event called "onSelectAll" that I could use, but I don’t know how to load all the data that has not yet been loaded, and select all the lines again after the data has finished loading.

Does anyone know of a simple solution to this problem?

+4
source share
1 answer

If you add the loadonce: true option to your grid, jqGrid will request all the data on the server. I think so, all lines will be loaded immediately.

0
source

Source: https://habr.com/ru/post/1434235/


All Articles