How to display information in jqGrid that there are not any data?

前端 未结 8 1550
不知归路
不知归路 2020-12-10 04:33

When jqGrid is empty I want to display single empty row inside the grid with information message that there are not any data. How is this possible? Thanks

8条回答
  •  离开以前
    2020-12-10 05:15

    $('#grid').jqGrid({
         loadComplete: function() {
                if ($("#grid").getGridParam("records")==0) {
                    $("#grid").addRowData(
                    $("#grid")
                        .empty()
                        .append('No records to display')
                     );
                }
            }
    });
    

提交回复
热议问题