Commits
Marie Verdonck authored 3fae13690fb
299 299 | |
300 300 | /** |
301 301 | * Make a new FindListRequest with given search method |
302 302 | * |
303 303 | * @param searchMethod The search method for the object |
304 304 | * @param options The [[FindListOptions]] object |
305 305 | * @param linksToFollow The array of [[FollowLinkConfig]] |
306 306 | * @return {Observable<RemoteData<PaginatedList<T>>} |
307 307 | * Return an observable that emits response from the server |
308 308 | */ |
309 - | protected searchBy(searchMethod: string, options: FindListOptions = {}, linksToFollow: Array<FollowLinkConfig<T>>): Observable<RemoteData<PaginatedList<T>>> { |
309 + | searchBy(searchMethod: string, options: FindListOptions = {}, linksToFollow: Array<FollowLinkConfig<T>>): Observable<RemoteData<PaginatedList<T>>> { |
310 310 | |
311 311 | const hrefObs = this.getSearchByHref(searchMethod, options, linksToFollow); |
312 312 | |
313 313 | return hrefObs.pipe( |
314 314 | find((href: string) => hasValue(href)), |
315 315 | tap((href: string) => { |
316 316 | this.requestService.removeByHrefSubstring(href); |
317 317 | const request = new FindListRequest(this.requestService.generateRequestId(), href, options); |
318 318 | request.responseMsToLive = 10 * 1000; |
319 319 | |