jqGrid - how to set grid to NOT load any data initially?

前端 未结 3 840
一整个雨季
一整个雨季 2021-02-01 18:46

How can you create a grid but not load any data?

If I omit the url option then the loadError callback is triggered.

Currently we set

3条回答
  •  逝去的感伤
    2021-02-01 19:14

    You should just use datatype: 'local' initially. At the moment when you need to load the data you should change the datatype to json or xml:

    $("#list").jqGrid('setGridParam',{datatype:'json'}).trigger('reloadGrid');
    

提交回复
热议问题