split each "record" on jqgrid to two rows - jqgrid

I have a jqgrid that has a lot of information for each record. It's causing a lot of horizontal scrolling and I'd like to avoid that.
I thought about using a subgrid, but every example I've seen for subgrid has the sub-info collapsed and I don't really want that. I just want the 2nd row for each record to be indented a bit.
Is there a good way to handle this besides using a subgrid. The other drawback to subgrid I've found is that it wants to load secondary data on the click to expand it. I'd rather just have all of the data loaded on the initial grid load.
TIA

Related

Use hierarchical tables in SlickGrid

We have a request from our designers to build tables something like this, with rows that expand to show essentially another sub-table underneath. In KendoUI documentation, this is called "Hierarchy."
We use SlickGrid v2.3 with a few additional plugins. We currently have tables with a similar row expand/collapse like this: https://mleibman.github.io/SlickGrid/examples/example5-collapsing.html . That does not allow for a completely different set of columns in the sub-table.
The question is, can this be done in SlickGrid or not?
It might be hard to do with current SlickGrid, there's no code that handles the hierarchical part itself so that would be lot of work to implement in SlickGrid. However it is implemented in Slickgrid-Universal, which is a wrapper on top of SlickGrid. You can see Example 5 and Example 6 which shows 2 types of Tree Data grids (hierarchical or parentId refs). We use it in production for a project that we have. Also note that this is not a grid within a grid, it's rather an expand/collapse the same as what you found in example5-collapsing.html, the only differences with SlickGrid is that Slickgrid-Universal has the code to deal with hierarchical data (filtering/sorting) while SlickGrid itself doesn't and also another nice to know thing is that expand/collapse is actually using data filtering behind the scene and you can see that in the total items displayed when you have the footer enabled.
Please note that I'm the author of Slickgrid-Universal and also a major contributor to SlickGrid as well
At the moment, it can't be done. In order to achieve its speed, Slickgrid enforces a fixed row height and a single scrolling canvas. It's just a different approach than used by HTML display grids.
You could put together a workaround using mutiple slickgrids or an embedded slickgrid in a group row, I suppose, but it would be messy.
One thing I have done is develop a SlickCombo, which is essentially a grid presented as a multi-column dropdown. It's a full grid and can offer editing.
That's probably as close as you'd get.
A comment: the MLeibman repo is long dead - you should be using: https://github.com/6pac/SlickGrid

BIRT- converting table to grid

Currently I'm working over a birt report with a table to display data. Now, i want to convert the same thing to grid, which provides better viewing and analysing capability. So, is there any easy way (in editing the XML or something) to convert the whole table to grid? Meanwhile, the complete data remains the same.
NB: I havn't yet used a bit with grid, never ever! Also m bit newbie to birt. So pardon me if I'm spiting out anything rubbish.
A table is a different element from a grid. There is not a button to push that will convert one to the other. You would need to add a grid element to your report and set it up like you want it to look.
I seriously doubt you want to do this though. a grid will only display the first record returned, unlike a table that will display all the records returned.
A related, but more reasonable question is how to convert a single-column table to a list or vice-versa.
I often need this table-to-list conversion for optimizing master-detail reports for (our customized version of) the WordEmitter, because this prevents superfluous nested tables in the Word output.
Fortunately, for tables without grouping this is relatively easy by editing the XML:
Change the corresponding opening and closing tag to a tag, remove the elements and the elements (but keep theirs contents).
Apart from that, James' is right: There is no reason to convert a table to a grid item, mainly because a table will display all records (while a grid displays only the first) while the table has all features of a grid (and more, like grouping).

jqgrid treegrid with level headers

I Have a TreeGrid with multiple levels I want to add Header for each level (i.e similar to that of subgrid, but i dont want to use it as the columns of subgrid doesnt align with the outer grid).
I would like to drive Porsche for free and that somebody should pay for the fuel additionally. :-) I think it's better that you use existing features of existing product if you want to use free products.
TreeGrid if jqGrid is the kind of grid. If the user collapse node the corresponding rows will be just made hidden. So the grid has column headers and no additional header can be created for tree node.
On the other side Subgrid, especially grid as subgrid, is more flexible. If you create subgrid inside of subGridRowExpanded callback you are free to set alignment, width or just everything from the child grid. You can even place any custom HTML an place of subgrid (see the demo from the answer). In the answer you will find an example how one can adjust width of subgrid if the column of main grid are resized.
So I think that you have to use grid as subgrid to implement your requirements. In any ways you should to write some additional code which implements your exact requirements.

jqgrid grouping with scrolled paging - stuck

I have a scenario where i need to use scrolled paging on my jqgrid, and it works perfectly. But now i need to add dynamic grouping capabilities to the grid as well. The problem I face, is that when I group the grid, only records in teh currently loaded page get grouped, and not the whole underlying dataset. Is there a way to acheive this using jqgrid.
a. Grouping groups all rows in a dataset, not just the ones loaded in a scrolled page in the grid.
b. When expanding such a group and scrolling, the grouped rows now follow scrolled paging
Any help here would be appreciated as I have been trying to figure this out for a while now with no luck :-(
Thanks
Lokesh

Telerik RadGrid refreshing a single row instead of using Rebind

I am using a RadGrid to display stock information. The data bound is a combination of 2 views and 2 tables. This is quite an intensive query, and the data behind it changes a lot. Now, when I update a value in a single row, I have to Rebind the data to update my grid (I use UpdateValues on the item, but it has no visible effect). This is taking too long to be user-friendly. Is there a simple way to work around it, so I can just update the row which has the changed data ?
I do not think there is a way to do that because the Telerik Grid is data bound control - hence to modify its source and refresh the data in the grid UI, you will need to bind all rows.
Dick

Resources