From b734ea21ac7be393c59cf9976f0e5ddeaf27d568 Mon Sep 17 00:00:00 2001 From: siddharth0905 Date: Thu, 22 Nov 2018 13:37:31 +0530 Subject: Service Workflow changes Service workflow change with few bug fixes Change-Id: Ice2376565bf46fb8d86fb6062654ec54bb2daa43 Issue-ID: SDC-1937 Signed-off-by: siddharth0905 --- .../operation-creator.component.html | 3 +- .../operation-creator.component.ts | 19 ++----- .../param-row/param-row.component.html | 6 +-- .../param-row/param-row.component.less | 2 +- .../param-row/param-row.component.ts | 58 +++++++++++++++++++--- 5 files changed, 61 insertions(+), 27 deletions(-) (limited to 'catalog-ui/src/app/ng2/pages/interface-operation/operation-creator') diff --git a/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/operation-creator.component.html b/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/operation-creator.component.html index 982cbb204c..6010bca10f 100644 --- a/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/operation-creator.component.html +++ b/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/operation-creator.component.html @@ -127,11 +127,10 @@ diff --git a/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/operation-creator.component.ts b/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/operation-creator.component.ts index 5d3b027493..a6c1fb1c4c 100644 --- a/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/operation-creator.component.ts +++ b/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/operation-creator.component.ts @@ -18,7 +18,6 @@ export interface OperationCreatorInput { isService: boolean } - @Component({ selector: 'operation-creator', templateUrl: './operation-creator.component.html', @@ -33,7 +32,7 @@ export class OperationCreatorComponent { workflows: Array = []; workflowVersions: Array = []; - inputProperties: Array = []; + inputProperties: Array = []; inputPropertyTypes: { [key: string]: string }; inputParameters: Array = []; @@ -76,19 +75,10 @@ export class OperationCreatorComponent { } ngOnInit() { - this.readonly = this.input.readonly; this.isService = this.input.isService; - this.enableWorkflowAssociation = this.input.enableWorkflowAssociation && !this.isService; - - this.inputProperties = _.map(this.input.inputProperties, - (input: InputBEModel) => new DropdownValue(input.uniqueId, input.name) - ); - - this.inputPropertyTypes = {}; - _.forEach(this.input.inputProperties, (input: InputBEModel) => { - this.inputPropertyTypes[input.uniqueId] = input.type; - }); + this.enableWorkflowAssociation = this.input.enableWorkflowAssociation; + this.inputProperties = this.input.inputProperties; const inputOperation = this.input.operation; this.operation = new OperationModel(inputOperation || {}); @@ -108,13 +98,12 @@ export class OperationCreatorComponent { } else { this.reconstructOperation(); } - } reconstructOperation = () => { const inputOperation = this.input.operation; if (inputOperation) { - if (!this.enableWorkflowAssociation || !inputOperation.workflowVersionId || this.isService) { + if (!this.enableWorkflowAssociation || !inputOperation.workflowVersionId) { this.inputParameters = this.noAssignInputParameters; this.outputParameters = this.noAssignOutputParameters; this.buildParams(); diff --git a/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/param-row/param-row.component.html b/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/param-row/param-row.component.html index 94d2fce1ea..9a5c101e87 100644 --- a/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/param-row/param-row.component.html +++ b/catalog-ui/src/app/ng2/pages/interface-operation/operation-creator/param-row/param-row.component.html @@ -1,5 +1,5 @@