Replies: 1 comment
-
First of all SlickGrid doesn't actually support Tree Data, the way I got it working is to keep 2 references of the data (1- flat dataset with parentId refs, 2- Tree Data hierarchical dataset). Whenever 1 changes, it has to recalculate/resort both. I use GETTER/SETTER on the dataset to trigger these update whenever the dataset is reassigned. There is a demo of inserting an item in both Tree Data demos, just take a look at how it's done |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi everyone,
I'm working with slickgrid-universal and facing a question about handling the movement of tree data. I have two potential approaches:
Using SlickGrid API: Leverage the SlickGrid API to handle the up and down movement of data in the tree structure.
Directly Modifying Dataset: Directly modify the position of data in the dataset and then re-render the grid.
Which method is more suitable for handling tree data movement? Does using the API ensure data consistency and proper grid rendering, or is directly modifying the dataset more effective?
I would appreciate any insights or suggestions on this!
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions