diff options
author | 2020-06-28 15:29:33 +0200 | |
---|---|---|
committer | 2020-06-28 15:29:33 +0200 | |
commit | 34862b8ae117126e055f3cb71b464e448d2c5827 (patch) | |
tree | 7caf9ca723f5f2b634891aa206199dd0f7b2078d /cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.service.ts | |
parent | 83221b2423060db32826065938edeebb5680b30f (diff) |
Add package deletion button
Issue-ID: CCSDK-2483
Signed-off-by: AhmedEldeeb50 <ahmed.eldeeb.ext@orange.com>
Change-Id: I7e1c0f80eb9e6073a1eb472bd6f042e8545c5ab7
Diffstat (limited to 'cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.service.ts')
-rw-r--r-- | cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.service.ts | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.service.ts b/cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.service.ts index 164d76601..c7f557121 100644 --- a/cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.service.ts +++ b/cds-ui/designer-client/src/app/modules/feature-modules/packages/configuration-dashboard/configuration-dashboard.service.ts @@ -1,8 +1,8 @@ -import {Injectable} from '@angular/core'; -import {ApiService} from '../../../../common/core/services/api.typed.service'; -import {BlueprintURLs} from '../../../../common/constants/app-constants'; -import {Observable} from 'rxjs'; -import {BluePrintDetailModel} from '../model/BluePrint.detail.model'; +import { Injectable } from '@angular/core'; +import { ApiService } from '../../../../common/core/services/api.typed.service'; +import { BlueprintURLs } from '../../../../common/constants/app-constants'; +import { Observable } from 'rxjs'; +import { BluePrintDetailModel } from '../model/BluePrint.detail.model'; @Injectable({ @@ -22,10 +22,13 @@ export class ConfigurationDashboardService { } public downloadResource(path: string) { - return this.api.getCustomized(BlueprintURLs.download + path, {responseType: 'blob'}); + return this.api.getCustomized(BlueprintURLs.download + path, { responseType: 'blob' }); } deployPost(body: any | null): Observable<any> { - return this.api.post(BlueprintURLs.deploy, body, {responseType: 'text'}); + return this.api.post(BlueprintURLs.deploy, body, { responseType: 'text' }); + } + deletePackage(id: string) { + return this.api.delete(BlueprintURLs.getOneBlueprint + '/' + id, { observe: 'response' }); } } |