X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=webapp-frontend%2Fsrc%2Fapp%2Fservices%2Fei%2Fproducer.service.ts;fp=webapp-frontend%2Fsrc%2Fapp%2Fservices%2Fei%2Fei.service.ts;h=2c4571d50b556cc4e171286f635ed23d2d5d3815;hb=refs%2Fchanges%2F71%2F6071%2F2;hp=1237b589d9902405ada9814194b9046e2fcf8694;hpb=8cf8165763380e8779c9420099faf2197fa161d4;p=portal%2Fnonrtric-controlpanel.git diff --git a/webapp-frontend/src/app/services/ei/ei.service.ts b/webapp-frontend/src/app/services/ei/producer.service.ts similarity index 70% rename from webapp-frontend/src/app/services/ei/ei.service.ts rename to webapp-frontend/src/app/services/ei/producer.service.ts index 1237b58..2c4571d 100644 --- a/webapp-frontend/src/app/services/ei/ei.service.ts +++ b/webapp-frontend/src/app/services/ei/producer.service.ts @@ -21,7 +21,7 @@ import { Injectable } from '@angular/core'; import { HttpClient } from '@angular/common/http'; import { Observable } from 'rxjs'; -import { EIJob, ProducerStatus, ProducerRegistrationInfo } from '@interfaces/ei.types'; +import { JobInfo, ProducerStatus, ProducerRegistrationInfo } from '@interfaces/producer.types'; /** * Services for calling the EI endpoints. @@ -29,12 +29,12 @@ import { EIJob, ProducerStatus, ProducerRegistrationInfo } from '@interfaces/ei. @Injectable({ providedIn: 'root' }) -export class EIService { +export class ProducerService { - private basePath = '/ei-producer/v1'; - readonly eiJobsPath = 'eijobs'; - readonly eiProducersPath = 'eiproducers'; - readonly eiProducerStatusPath = 'status'; + private basePath = '/data-producer/v1'; + readonly jobsPath = 'info-jobs'; + readonly producersPath = 'info-producers'; + readonly producerStatusPath = 'status'; private buildPath(...args: any[]) { let result = this.basePath; @@ -49,22 +49,22 @@ export class EIService { } getProducerIds(): Observable { - const url = this.buildPath(this.eiProducersPath); + const url = this.buildPath(this.producersPath); return this.httpClient.get(url); } - getJobsForProducer(producerId: string): Observable { - const url = this.buildPath(this.eiProducersPath, producerId, this.eiJobsPath); - return this.httpClient.get(url); + getJobsForProducer(producerId: string): Observable { + const url = this.buildPath(this.producersPath, producerId, this.jobsPath); + return this.httpClient.get(url); } getProducer(producerId: string): Observable { - const url = this.buildPath(this.eiProducersPath, producerId); + const url = this.buildPath(this.producersPath, producerId); return this.httpClient.get(url); } getProducerStatus(producerId: string): Observable { - const url = this.buildPath(this.eiProducersPath, producerId, this.eiProducerStatusPath); + const url = this.buildPath(this.producersPath, producerId, this.producerStatusPath); return this.httpClient.get(url); } }