JQGrid - How Can We make an Custom Row Detail

前端 未结 1 768
栀梦
栀梦 2020-11-30 11:46

Some one give me the some Sample Code to make my Grid like this.I read in document that jqgrid just supports subgrid.

like this page in Hierachy http://trirand.net/d

相关标签:
1条回答
  • 2020-11-30 12:01

    On the page Custom Row Detail you can see how you can use subGridRowExpanded event handle to show custom HTML data as subgrid data. In general if you have any standard jqGrid you can implement the same very easy. You should just add subGrid: true to the grid and define subGridRowExpanded which append html to the subgrid:

    subGridRowExpanded: function(subgrid_id, row_id) {
        var html = "<span>Some HTML text which corresponds the row with id="+
                   row_id + "</span><br/>";
        $("#" + subgrid_id).append(html);
    }
    

    You can see this live here:

    0 讨论(0)
提交回复
热议问题