- connect(collectionViewer: CollectionViewer): Observable<ANRNeighborCellRelation[]> {
- const dataMutations = [
- this.relationsSubject.asObservable(),
- this.sort.sortChange
- ];
- return merge(...dataMutations).pipe(map(() => {
- return this.getSortedData([...this.relationsSubject.getValue()]);
- }));
- }
+ loadTable(ggnodeb: string = '', servingCellNrcgi: string = '', neighborCellNrpci: string = '') {
+ this.loadingSubject.next(true);
+ this.anrXappService.getNcrtInfo(ggnodeb, servingCellNrcgi, neighborCellNrpci)
+ .pipe(
+ catchError( (her: HttpErrorResponse) => {
+ console.log('ANRXappDataSource failed: ' + her.message);
+ this.notificationService.error('Failed to get data: ' + her.message);
+ return of([]);
+ }),
+ finalize(() => this.loadingSubject.next(false))
+ )
+ .subscribe( (ncrt: ANRNeighborCellRelation[]) => {
+ this.rowCount = ncrt.length;
+ this.relationsSubject.next(ncrt);
+ });
+ }