Closed desuraghu closed 4 years ago
These kind of questions should be asked on Stack Overflow.
You can try any of these things
grid.setColumns()
but that will probably side effect on the grid (especially the header menu, grid menu and column picker), the problem is that Angular-Slickgrid keeps 2 references for all the columns (shown+hidden) & the visible columns for these pickers to work properly and if you use grid.setColumns()
yourself then you're bypassing Angular-Slickgrid and the internal references won't be in sync and the list of columns might be wrong in these picker menus.
setColumns()
but it also updates the 2 references that I just wrote aboutwidth
and/or maxWidth
to 1
which will make it look it's hidden but in fact it's just not very wide to show up
I guess the number 4. is probably what you're looking for... again this type of question should be asked on Stack Overflow, where I pulled the answer as well.
I am looking for an option hide the row, not the column. Will post the same in stack-overflow.
Ahh then I wrote my long answer for the wrong thing, then Filter or Formatters are the only way that I can think of. Filter would be the best but it will probably conflict with the Filters used by Angular-Slickgrid (if you're using any of the Angular-Slickgrid Filters). The Formatters on the other end could hide the values in certain cases but they would have to be added to each and every column definitions and it won't hide the entire row just the data.
On the Filter side, which again is probably the only way to hide a full row, you could try combining your filtering with the single search filter approach (see this Example).
I can't help you more than that, Stack Overflow is again always better for such questions.
General Topic
Would like to know is there any option available to hide a row in the grid (other than filters)
Your Environment
Context or Topic
Hiding a row in the grid based on few parameters available in the row object (item)
Expected Behavior
If the parameters are satisfied, the row should be hidden
Current Behavior
Not sure weather there is any option available to hide a the row. If we try to hide the row by adding CSS style, the row is not visible. But the space is occupied in the grid in that position.
Possible Solution
Need to have an option to hide the row.