ISSSTELEON WebApp
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
import { HttpClient, HttpContext, HttpResponse } from '@angular/common/http';
|
||||
import { Observable } from 'rxjs';
|
||||
import { filter, map } from 'rxjs/operators';
|
||||
import { StrictHttpResponse } from '../../strict-http-response';
|
||||
import { RequestBuilder } from '../../request-builder';
|
||||
import { Analysis } from '../../models/analysis';
|
||||
export interface Study$Params {
|
||||
eeg_id: string;
|
||||
}
|
||||
export function study(
|
||||
http: HttpClient,
|
||||
rootUrl: string,
|
||||
params: Study$Params,
|
||||
context?: HttpContext,
|
||||
): Observable<StrictHttpResponse<Analysis>> {
|
||||
const rb = new RequestBuilder(rootUrl, study.PATH, 'get');
|
||||
if (params) {
|
||||
rb.path('eeg_id', params.eeg_id, {});
|
||||
}
|
||||
return http.request(rb.build({ responseType: 'json', accept: 'application/json', context })).pipe(
|
||||
filter((r: any): r is HttpResponse<any> => r instanceof HttpResponse),
|
||||
map((r: HttpResponse<any>) => {
|
||||
return r as StrictHttpResponse<Analysis>;
|
||||
}),
|
||||
);
|
||||
}
|
||||
study.PATH = '/tea/eegs/{eeg_id}';
|
||||
Reference in New Issue
Block a user