aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--catalog-ui/src/app/ng2/pages/composition/interface-operatons/interface-operations.component.ts18
1 files changed, 13 insertions, 5 deletions
diff --git a/catalog-ui/src/app/ng2/pages/composition/interface-operatons/interface-operations.component.ts b/catalog-ui/src/app/ng2/pages/composition/interface-operatons/interface-operations.component.ts
index b14d0dda65..17f697ecda 100644
--- a/catalog-ui/src/app/ng2/pages/composition/interface-operatons/interface-operations.component.ts
+++ b/catalog-ui/src/app/ng2/pages/composition/interface-operatons/interface-operations.component.ts
@@ -238,15 +238,23 @@ export class InterfaceOperationsComponent {
private updateInterfaceOperation() {
this.isLoading = true;
- const operationUpdated: InterfaceOperationModel = this.modalInstance.instance.dynamicContent.instance.operationToUpdate;
+ const interfaceOperationHandlerComponentInstance: InterfaceOperationHandlerComponent = this.modalInstance.instance.dynamicContent.instance;
+ const operationUpdated: InterfaceOperationModel = interfaceOperationHandlerComponentInstance.operationToUpdate;
+ const isArtifactChecked = interfaceOperationHandlerComponentInstance.enableAddArtifactImplementation;
+ if (!isArtifactChecked) {
+ let artifactName = interfaceOperationHandlerComponentInstance.artifactName;
+ artifactName = artifactName === undefined ? '' : artifactName;
+ operationUpdated.implementation = new ArtifactModel({'artifactName': artifactName} as ArtifactModel);
+ }
this.topologyTemplateService.updateComponentInstanceInterfaceOperation(
this.componentMetaData.uniqueId,
this.componentMetaData.componentType,
this.componentInstanceSelected.uniqueId,
- operationUpdated).subscribe((updatedComponentInstance: ComponentInstance) => {
- this.componentInstanceSelected = new ComponentInstance(updatedComponentInstance);
- this.initComponentInstanceInterfaceOperations();
- });
+ operationUpdated)
+ .subscribe((updatedComponentInstance: ComponentInstance) => {
+ this.componentInstanceSelected = new ComponentInstance(updatedComponentInstance);
+ this.initComponentInstanceInterfaceOperations();
+ });
this.modalServiceNg2.closeCurrentModal();
this.isLoading = false;
}