From c4de387f86bd84f788cce24c005e79e8473c29a7 Mon Sep 17 00:00:00 2001 From: Nicolas Constant Date: Thu, 7 Mar 2024 01:17:04 -0500 Subject: [PATCH] sort list in alphabetical order, fix #633 --- .../manage-account/my-account/my-account.component.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/app/components/floating-column/manage-account/my-account/my-account.component.ts b/src/app/components/floating-column/manage-account/my-account/my-account.component.ts index 58710d92..0819fc95 100644 --- a/src/app/components/floating-column/manage-account/my-account/my-account.component.ts +++ b/src/app/components/floating-column/manage-account/my-account/my-account.component.ts @@ -122,6 +122,17 @@ export class MyAccountComponent implements OnInit, OnDestroy { } } }) + .then(_ => { + this.availableLists.sort((a,b) => { + if (a.name < b.name) { + return -1; + } + if (a.name > b.name) { + return 1; + } + return 0; + }); + }) .catch(err => { this.notificationService.notifyHttpError(err, this.account.info); });