566339db8a2bad2d52e6a3246414591d1ae4419e
[ccsdk/cds.git] /
1 import {Injectable} from '@angular/core';
2 import {ApiService} from '../../../../common/core/services/api.typed.service';
3 import {BlueprintURLs} from '../../../../common/constants/app-constants';
4 import {Observable} from 'rxjs';
5 import {BluePrintDetailModel} from '../model/BluePrint.detail.model';
6
7
8 @Injectable({
9     providedIn: 'root'
10 })
11 export class ConfigurationDashboardService {
12     constructor(private api: ApiService<BluePrintDetailModel>) {
13
14     }
15
16     getBluePrintModel(id: string): Observable<BluePrintDetailModel> {
17         return this.api.getOne(BlueprintURLs.getOneBlueprint + '/' + id);
18     }
19
20
21     public downloadResource(id: string) {
22         return this.api.getCustomized(id, {responseType: 'blob'});
23     }
24
25 }