diff options
author | Ahmed Abbas <ahmad.helmy@orange.com> | 2020-02-29 17:01:58 +0200 |
---|---|---|
committer | Ahmed Abbas <ahmad.helmy@orange.com> | 2020-02-29 17:01:58 +0200 |
commit | 2068f014427ec1a2b782677557b4af0f1723e40c (patch) | |
tree | 87924c280d1b5444758c109c1514e9c98235ec51 /cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/graph.util.ts | |
parent | 886d352ec99fe5281c281c16f8d4b9908fb0dcc3 (diff) |
enhance loading topologyTemplate from source
- fix bug when rename stepName in workflow
- tune directGraph options to fix Elements positioning when loading from source
Issue-ID: CCSDK-1779
Issue-ID: CCSDK-2129
Signed-off-by: Ahmed Abbas <ahmad.helmy@orange.com>
Change-Id: Iee0d5b98266bee5b9920c557dea46a69c8434d85
Diffstat (limited to 'cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/graph.util.ts')
-rw-r--r-- | cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/graph.util.ts | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/graph.util.ts b/cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/graph.util.ts index 9ba7271fb..fd4dd35e4 100644 --- a/cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/graph.util.ts +++ b/cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/graph.util.ts @@ -211,4 +211,18 @@ export class GraphUtil { return !parentCell.get('embeds') || parentCell.get('embeds').length < 1; } + getActionSiblings(actionCell: joint.shapes.app.ActionElement, + boardGraph: joint.dia.Graph + ): joint.shapes.app.ActionElement[] { + const cellId = actionCell.id; + const siblings = boardGraph.getCells().filter(elem => { + const type = elem.attributes.type; + const elemId = elem.id; + return (type !== undefined && type === 'app.ActionElement' + && elemId !== cellId); + }) as joint.shapes.app.ActionElement[]; + console.log('siblings', siblings); + return siblings; + } + } |