diff --git a/frontend/src/app/modules/boards/boards-sidebar/boards-menu.component.ts b/frontend/src/app/modules/boards/boards-sidebar/boards-menu.component.ts index c495a00dd4..1b733b0e26 100644 --- a/frontend/src/app/modules/boards/boards-sidebar/boards-menu.component.ts +++ b/frontend/src/app/modules/boards/boards-sidebar/boards-menu.component.ts @@ -6,6 +6,7 @@ import {BoardCacheService} from "core-app/modules/boards/board/board-cache.servi import {DynamicBootstrapper} from "core-app/globals/dynamic-bootstrapper"; import {AngularTrackingHelpers} from "core-components/angular/tracking-functions"; import {MainMenuNavigationService} from "core-components/main-menu/main-menu-navigation.service"; +import {map} from "rxjs/operators"; @Component({ selector: 'boards-menu', @@ -15,7 +16,15 @@ import {MainMenuNavigationService} from "core-components/main-menu/main-menu-nav export class BoardsMenuComponent { trackById = AngularTrackingHelpers.compareByAttribute('id'); - public boards$:Observable = this.boardCache.observeAll(); + public boards$:Observable = this.boardCache.observeAll().pipe( + map((boards:Board[]) => { + return boards.sort(function(a, b){ + if(a.name < b.name) { return -1; } + if(a.name > b.name) { return 1; } + return 0; + }); + }) + ); constructor(private readonly boardService:BoardService, private readonly boardCache:BoardCacheService,