diff --git a/docs/releases/v2.14.2.md b/docs/releases/v2.14.2.md index ee12fa3aeae981f9c1f5d1c914bd8644cdc40928..03ab8f466badffdcb696a03ccd7fe80eaa55a516 100644 --- a/docs/releases/v2.14.2.md +++ b/docs/releases/v2.14.2.md @@ -11,8 +11,11 @@ - Added reference to Julich Brain 3.1 - Fixed unsupported parcellations - Fixed navigation to ICBM152/JulichBrain3.1 on startup +- Fixed siibra-api endpoint definition +- Added feedback when fetch feature encounters error ## Behind the Scenes - Updated CI/CD pipelines - Removed unused pipes +- Removed unused display function in connectivity component diff --git a/src/features/connectivity/connectivityBrowser/connectivityBrowser.component.ts b/src/features/connectivity/connectivityBrowser/connectivityBrowser.component.ts index 8d94a608f91eb08dc21222042809b3b35c34510e..c82856be5e940e0963d64f8ee395779c03ee6451 100644 --- a/src/features/connectivity/connectivityBrowser/connectivityBrowser.component.ts +++ b/src/features/connectivity/connectivityBrowser/connectivityBrowser.component.ts @@ -359,10 +359,6 @@ export class ConnectivityBrowserComponent implements OnChanges { shareReplay(1), )), ) - - subjectDisplayWith(subId: number): string { - return this.selectedDataset?.subjects[subId] || `${subId}` - } selectedDatasetAdditionalInfos$ = this.selectedDataset$.pipe( map(ds => ds ? ds.datasets : []) diff --git a/src/features/connectivity/connectivityBrowser/connectivityBrowser.template.html b/src/features/connectivity/connectivityBrowser/connectivityBrowser.template.html index e57a3d6a080bd83ed759529a61a2202cfc047fad..7fc4c67ab1d0f1892406747db07a6632e348a05a 100644 --- a/src/features/connectivity/connectivityBrowser/connectivityBrowser.template.html +++ b/src/features/connectivity/connectivityBrowser/connectivityBrowser.template.html @@ -77,7 +77,6 @@ </mat-label> <mat-slider [min]="0" [max]="(view$ | async | getProperty : 'numSubjects') - 1" - [displayWith]="subjectDisplayWith" step="1" [discrete]="true" class="w-100"> diff --git a/src/features/list/list.directive.ts b/src/features/list/list.directive.ts index 119fae57b2a5933e760567cac51b274ff93132f3..11f5c903165e6b1167466f5e2dd869ada9c5e732 100644 --- a/src/features/list/list.directive.ts +++ b/src/features/list/list.directive.ts @@ -80,26 +80,36 @@ export class ListDirective extends FeatureBase implements OnDestroy{ return [] } - const results = await this.sapi.v3Get(`/feature/${route}`, { - query: { - ...this.queryParams, - ...query, - page - } - }).pipe( - switchMap(resp => { - totalPages = resp.pages || 0 - this.#total.next(resp.total || 0) - if (resp.items.length === 0) { - return of([] as TranslatedFeature[]) + try { + + const results = await this.sapi.v3Get(`/feature/${route}`, { + query: { + ...this.queryParams, + ...query, + page } - return forkJoin( - resp.items.map(feature => translateV3Entities.translateFeature(feature)) - ) - }) - ).toPromise() - page += 1 - return results + }).pipe( + switchMap(resp => { + totalPages = resp.pages || 0 + this.#total.next(resp.total || 0) + if (resp.items.length === 0) { + return of([] as TranslatedFeature[]) + } + return forkJoin( + resp.items.map(feature => translateV3Entities.translateFeature(feature)) + ) + }) + ).toPromise() + page += 1 + return results + } catch (e) { + console.error(`Datasource Error:`) + console.error(e) + + totalPages = 0 + this.#total.next(0) + return [] + } }, annotations: { ...this.queryParams, diff --git a/src/main.module.ts b/src/main.module.ts index 09b91d95c17b9382621ca702baa78d06f39a89ee..2735d71ea4b665116e3e090e446e166ac53049fa 100644 --- a/src/main.module.ts +++ b/src/main.module.ts @@ -51,7 +51,7 @@ import { LayerCtrlEffects } from './viewerModule/nehuba/layerCtrl.service/layerC import { NehubaNavigationEffects } from './viewerModule/nehuba/navigation.service/navigation.effects'; import { CONST } from "common/constants" import { ViewerCommonEffects } from './viewerModule'; -import { environment } from './environments/environment.common'; +import { environment } from './environments/environment'; import { SAPI } from './atlasComponents/sapi'; @NgModule({