From 4dd2f9d159e12e888e4e6dd9dda245e296e38b98 Mon Sep 17 00:00:00 2001 From: ShaabanEltanany Date: Mon, 26 Oct 2020 13:46:14 +0200 Subject: adding inputs and outputs to entry definition (Designer) Issue-ID: CCSDK-2943 Signed-off-by: ShaabanEltanany Change-Id: Iffd5c80ecf3fa35b21ab14b8c70308e0d3ee2a50 --- .../feature-modules/packages/designer/designer.component.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/designer.component.ts') diff --git a/cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/designer.component.ts b/cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/designer.component.ts index d0af828e8..77e0ceed6 100644 --- a/cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/designer.component.ts +++ b/cds-ui/designer-client/src/app/modules/feature-modules/packages/designer/designer.component.ts @@ -231,6 +231,7 @@ export class DesignerComponent implements OnInit, OnDestroy { rankDir: 'TB' }); this.actions = []; + console.log('here'); for (const workflowsKey in topologtTemplate.workflows) { if (workflowsKey && !this.actions.includes(workflowsKey)) { this.actions.push(workflowsKey); @@ -273,8 +274,8 @@ export class DesignerComponent implements OnInit, OnDestroy { width: 1100, gridSize: 10, drawGrid: true, - // background: { - // color: 'rgba(0, 255, 0, 0.3)' + // background: { + // color: 'rgba(0, 255, 0, 0.3)' // }, cellViewNamespace: joint.shapes }); @@ -326,9 +327,13 @@ export class DesignerComponent implements OnInit, OnDestroy { insertCustomActionIntoBoard() { console.log('saving action to store action workflow....'); - const actionName = this.graphUtil.generateNewActionName(); + let actionName = this.graphUtil.generateNewActionName(); + while (this.actions.includes(actionName)) { + actionName = this.graphUtil.generateNewActionName(); + } this.graphUtil.createCustomActionWithName(actionName, this.boardGraph); this.designerStore.addDeclarativeWorkFlow(actionName); + this.actions.push(actionName); } stencilPaperEventListeners() { @@ -475,5 +480,7 @@ export class DesignerComponent implements OnInit, OnDestroy { openFunctionAttributes(customActionName: string) { console.log('opening here function attributes'); + this.actionAttributesSideBar = true; + this.designerStore.setCurrentAction(customActionName); } } -- cgit 1.2.3-korg