[ANGULAR] Check if programmatically added dependency would cause a cycle
Posted: Thu Mar 30, 2023 1:28 pm
by attila.posta
Hi!
Before adding records to dependencyStore, how can I check if it would be valid / non-circular?
I don't want to let the cycle popup come up, I simply need a boolean value to decide what to do next.
It's a method coming from the Engine class which ends up on the Gantt ProjectModel. I doubt it appears in TypeScript interface the Gantt ships but rest assured it is there on the model:
The method returns a Promise which when resolved provides values: 0 - dependency is ok, 1 - it builds a cycle, 2 - it duplicates an already existing dependency
Re: [ANGULAR] Check if programmatically added dependency would cause a cycle