2018-10-05 17:00:54 +02:00
|
|
|
import { HttpHeaders } from '@angular/common/http';
|
|
|
|
import { Injectable } from '@angular/core';
|
2018-10-12 17:17:31 +02:00
|
|
|
import { Observable } from 'rxjs';
|
2019-01-18 18:03:45 +01:00
|
|
|
import { environment } from '../../../../environments/environment';
|
|
|
|
import { ExternalSourcesConfiguration } from '../../model/external-sources/external-sources-configuration';
|
|
|
|
import { BaseHttpService } from '../http/base-http.service';
|
2020-03-26 17:44:12 +01:00
|
|
|
import { ConfigurationService } from '../configuration/configuration.service';
|
2018-05-28 11:50:42 +02:00
|
|
|
|
|
|
|
@Injectable()
|
|
|
|
export class ExternalSourcesConfigurationService {
|
|
|
|
|
2018-10-05 17:00:54 +02:00
|
|
|
private actionUrl: string;
|
|
|
|
private headers: HttpHeaders;
|
2018-05-28 11:50:42 +02:00
|
|
|
|
2020-03-26 17:44:12 +01:00
|
|
|
constructor(private http: BaseHttpService, private configurationService: ConfigurationService) {
|
|
|
|
this.actionUrl = configurationService.server + 'common/';
|
2018-10-05 17:00:54 +02:00
|
|
|
}
|
2018-05-28 11:50:42 +02:00
|
|
|
|
2018-10-05 17:00:54 +02:00
|
|
|
public getExternalSourcesConfiguration(): Observable<ExternalSourcesConfiguration> {
|
|
|
|
return this.http.get<ExternalSourcesConfiguration>(this.actionUrl + 'externalSourcesConfiguration', { headers: this.headers });
|
|
|
|
}
|
2018-05-28 11:50:42 +02:00
|
|
|
|
|
|
|
}
|