From ec5c8fddfb0ba0e40b19cd438533114652448d0f Mon Sep 17 00:00:00 2001 From: imamSidero Date: Tue, 29 Aug 2023 11:39:37 +0100 Subject: Provide UI support to upload csar to update service Upload capability is porvided in tosca artifact to update the service Issue-ID: SDC-4605 Signed-off-by: Imam hussain Change-Id: I075250f91e6e68f007298d1b982db86244a696db --- .../ng2/services/component-services/topology-template.service.ts | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'catalog-ui/src/app/ng2/services') diff --git a/catalog-ui/src/app/ng2/services/component-services/topology-template.service.ts b/catalog-ui/src/app/ng2/services/component-services/topology-template.service.ts index 0386a1577a..0af8c737de 100644 --- a/catalog-ui/src/app/ng2/services/component-services/topology-template.service.ts +++ b/catalog-ui/src/app/ng2/services/component-services/topology-template.service.ts @@ -80,6 +80,12 @@ export class TopologyTemplateService { return this.http.put(this.baseUrl + this.getServerTypeUrl(componentType) + componentId + '/toscaTemplate', file) } + putServiceToscaModel(componentId: string, componentType: string, file) { + let uploadData:FormData = new FormData(); + uploadData.append('upload', file); + return this.http.put(this.baseUrl + this.getServerTypeUrl(componentType) + componentId + '/toscaModel', uploadData); + } + getFullComponent(componentType: string, uniqueId: string): Observable { return this.http.get(this.baseUrl + this.getServerTypeUrl(componentType) + uniqueId); } -- cgit 1.2.3-korg