Skip to content
This repository has been archived by the owner on Jul 29, 2019. It is now read-only.

timeline: 3rd level hierarchy for nested groups #2846

Open
susemiessner opened this issue Mar 8, 2017 · 11 comments
Open

timeline: 3rd level hierarchy for nested groups #2846

susemiessner opened this issue Mar 8, 2017 · 11 comments

Comments

@susemiessner
Copy link

I have the need for a 3-level hierarchy of nested groups. 2 level hierarchies work fine in release 4.18.1 but when I add a third hierarchy level the last level gets messed up and displayed in a weird order. I can actually open and close the items using the arrow, but they are not displayed under their parent but in some random other place

@yotamberk
Copy link
Contributor

I specifically treated only 2-nd level nested groups. 3-rd and higher hierarchy needs to be implemented.

@bradh
Copy link
Contributor

bradh commented Mar 30, 2017

Is this a duplicate of #1934 ?

@JobrianTrinidad
Copy link

Hi, I developed a code to support N level of hierarchy for Nested groups, using recursion. There are still some work to be done, but functional. Please forgive my coding as I'm not familiar with Java script syntax. If anybody interested in the code, commits are in my repository. Again, please forgive me if I screwed up my git commits too.

@zsoltlengyelit
Copy link

Hi @JobrianTrinidad
I've checked out you repo. It's very cool you spent time on it. It's not finished yet, right?
Could you give me some hints what is missing and how it can be solved? Thanks for your help

@JobrianTrinidad
Copy link

Hi @zsoltlengyelit
I'm finished working on it. It works fine even with big records - that's after I removed and rewrote my recursion function. I welcome any comments or suggestions.

@yotamberk
Copy link
Contributor

@JobrianTrinidad Would you consider adding it as a PR?

@JobrianTrinidad
Copy link

Hi @yotamberk
Sure.

@McSpidey
Copy link

Did this PR get added?

@timjp87
Copy link

timjp87 commented Jan 10, 2018

@JobrianTrinidad I built the master branch of your repo and bundled the resulting vis.js file from /dist with webpack for my project. It draws the timeline but when I try to expand a level I get a lot of errors in console. It starts with:

Uncaught RangeError: Maximum call stack size exceeded
at new Group (vis.js:23773)
at vis.js:21698
at Array.forEach ()
at ItemSet._onAddGroups (vis.js:21683)
at Object.add [as callback] (vis.js:20764)
at DataView.DataSet._trigger (vis.js:8329)
at DataView._onEvent (vis.js:9678)
at Object.DataView.listener [as callback] (vis.js:9334)
at DataSet._trigger (vis.js:8329)
at DataSet.update (vis.js:8425)

Followed by many:
Uncaught TypeError: Cannot read property 'dom' of undefined
at ItemSet.groupFromTarget (vis.js:22883)
at Timeline.getEventProperties (vis.js:17721)
at HTMLDivElement.Timeline.dom.root.onmouseover (vis.js:17307)

My dataset has 95 groups and is 4 levels deep starting with 5 top level groups.

@Jogai
Copy link

Jogai commented Apr 20, 2018

Hey @JobrianTrinidad
I dont think you made a PR? I tried making a fork and then pulling your changes, but the branches differ too much to do that with git (or I'm not skilled enough to do that). I can however copy the changes from your branch into the latest develop branch and get it to work. Now I can make a PR, but that would list me as the author, while its your work. I rather let you contribute your changes to vis.
However I need it badly so if you dont care let me know, then I can do the PR...

@JobrianTrinidad
Copy link

Hi @Jogai ,
I'm sorry I wasn't able to look on to this. I am working on something else, and we don't often use this library. I don't mind if you do the PR. I'll appreciate if this feature becomes part of the library.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants