Skip to content

Commit

Permalink
MB-51582 - Workbench sidebar scopes listed in random order
Browse files Browse the repository at this point in the history
With the change to retrieve scope and collection information from the
query service, in order to support limited permissions users, I
neglected to sort the list of scopes alphabetically.

Change-Id: I924358d08a314dce084505b9a989eb7aeb95643c
Reviewed-on: https://review.couchbase.org/c/query-ui/+/172844
Tested-by: Eben Haber <eben@couchbase.com>
Reviewed-by: Pavel Blagodov <stochmail@gmail.com>
Well-Formed: Restriction Checker
  • Loading branch information
ebenhaber authored and pavel-blagodov committed Mar 25, 2022
1 parent 6ee192c commit 840fe55
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions query-ui/angular-services/qw.query.workbench.service.js
Expand Up @@ -2560,6 +2560,7 @@ function getQwQueryService(
.map(function (scope_name) {
return {id: scope_name, expanded: isExpanded(bucket.name, scope_name)};
});
bucket.scopeArray.sort((c1, c2) => c1.id.localeCompare(c2.id));
bucket.collections.sort((c1, c2) => c1.name.localeCompare(c2.name));

// if we are going to show schemas, we need to first get all the indexes, then get the schemas
Expand Down

0 comments on commit 840fe55

Please sign in to comment.