According to this idea we can't declaratively have dependencies or hierarchical tasks in APEX Gantt Charts:
https://apexapps.oracle.com/pls/apex/apex_pm/r/ideas/details?idea=FR-2384
In Oracle JET it is available:
https://www.oracle.com/webfolder/technetwork/jet/jetCookbook.html?component=gantt&demo=dependencies

Can this be achieved with JS Code using the attribute “Initialization JavaScript Function" ?