my-dspace-page.component.ts (dspace-angular-dspace-7.0) | : | my-dspace-page.component.ts (dspace-angular-dspace-7.1) | ||
---|---|---|---|---|
skipping to change at line 82 | skipping to change at line 82 | |||
* The current paginated search options | * The current paginated search options | |||
*/ | */ | |||
searchOptions$: Observable<PaginatedSearchOptions>; | searchOptions$: Observable<PaginatedSearchOptions>; | |||
/** | /** | |||
* The current available sort options | * The current available sort options | |||
*/ | */ | |||
sortOptions$: Observable<SortOptions[]>; | sortOptions$: Observable<SortOptions[]>; | |||
/** | /** | |||
* The current relevant scopes | ||||
*/ | ||||
scopeListRD$: Observable<DSpaceObject[]>; | ||||
/** | ||||
* Emits true if were on a small screen | * Emits true if were on a small screen | |||
*/ | */ | |||
isXsOrSm$: Observable<boolean>; | isXsOrSm$: Observable<boolean>; | |||
/** | /** | |||
* Subscription to unsubscribe from | * Subscription to unsubscribe from | |||
*/ | */ | |||
sub: Subscription; | sub: Subscription; | |||
/** | /** | |||
skipping to change at line 147 | skipping to change at line 142 | |||
ngOnInit(): void { | ngOnInit(): void { | |||
this.configurationList$ = this.searchConfigService.getAvailableConfiguration Options(); | this.configurationList$ = this.searchConfigService.getAvailableConfiguration Options(); | |||
this.searchOptions$ = this.searchConfigService.paginatedSearchOptions; | this.searchOptions$ = this.searchConfigService.paginatedSearchOptions; | |||
this.sub = this.searchOptions$.pipe( | this.sub = this.searchOptions$.pipe( | |||
tap(() => this.resultsRD$.next(null)), | tap(() => this.resultsRD$.next(null)), | |||
switchMap((options: PaginatedSearchOptions) => this.service.search(options ).pipe(getFirstSucceededRemoteData()))) | switchMap((options: PaginatedSearchOptions) => this.service.search(options ).pipe(getFirstSucceededRemoteData()))) | |||
.subscribe((results) => { | .subscribe((results) => { | |||
this.resultsRD$.next(results); | this.resultsRD$.next(results); | |||
}); | }); | |||
this.scopeListRD$ = this.searchConfigService.getCurrentScope('').pipe( | ||||
switchMap((scopeId) => this.service.getScopes(scopeId)) | ||||
); | ||||
this.context$ = this.searchConfigService.getCurrentConfiguration('workspace' ) | this.context$ = this.searchConfigService.getCurrentConfiguration('workspace' ) | |||
.pipe( | .pipe( | |||
map((configuration: string) => { | map((configuration: string) => { | |||
if (configuration === 'workspace') { | if (configuration === 'workspace') { | |||
return Context.Workspace; | return Context.Workspace; | |||
} else { | } else { | |||
return Context.Workflow; | return Context.Workflow; | |||
} | } | |||
}) | }) | |||
); | ); | |||
End of changes. 2 change blocks. | ||||
9 lines changed or deleted | 0 lines changed or added |