0

I am trying to use jqGrid to display tabular data in groups (shown in image below) and having trouble displaying headers for each group (as Hierarchical jqGrid displays columns headers for child grids). I have included how default jqGrid Grouping looks like.

enter image description here

Is there any way to implement this? Also is it possible to display summary in group header row instead of footer?

Thank you

somedude
  • 169
  • 3
  • 12

1 Answers1

0

What you want contains too many changes in the standard structure of the grid. I suppose that you want that the "Groups" header and sub-headers "Group Header 1", "Group Header 2", "Group Header 3" should be resizable. It seems me a little too difficult in the implementation.

Probably you should use better subgrids instead of data grouping? If you need hold the width of last columns of subgrids synchronous with the width of last columns of the main grid you can use approach which I described in the answer. You can use resizeStop callback to catch changing of column size and you can call setColWidth method (see the answer for more details) on another grid (on main grid and other opened subgrids).

Community
  • 1
  • 1
Oleg
  • 220,925
  • 34
  • 403
  • 798
  • Thank you @Oleg, I guess I'll use the subgrid. The grid does not need resizable columns so if I set the subgrid column width to match the main grid, it will be fine. It will just need some more code to setup sub grid and I was thinking if I could avoid that. – somedude Jul 27 '14 at 18:33
  • @csharp_beginer: You are welcome! Subgrids, seems to me too, are the mostly close to your requirements. – Oleg Jul 27 '14 at 19:25