diff options
author | Stas Vilchik <vilchiks@gmail.com> | 2017-05-04 13:55:51 +0200 |
---|---|---|
committer | Stas Vilchik <vilchiks@gmail.com> | 2017-05-04 13:58:08 +0200 |
commit | 488efb9ad0ff53b123ff2e26e5c182b83a219a69 (patch) | |
tree | fd371c56972e6408adbbbc403ddccea27b25ce04 /server/sonar-web/src/main/js/apps/account | |
parent | 02cc6c36d46f4b50781b750cdae286fd28dd0979 (diff) | |
download | sonarqube-488efb9ad0ff53b123ff2e26e5c182b83a219a69.tar.gz sonarqube-488efb9ad0ff53b123ff2e26e5c182b83a219a69.zip |
sort my organizations by name
Diffstat (limited to 'server/sonar-web/src/main/js/apps/account')
-rw-r--r-- | server/sonar-web/src/main/js/apps/account/organizations/OrganizationsList.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/server/sonar-web/src/main/js/apps/account/organizations/OrganizationsList.js b/server/sonar-web/src/main/js/apps/account/organizations/OrganizationsList.js index 222f9df73ab..3969d08b0df 100644 --- a/server/sonar-web/src/main/js/apps/account/organizations/OrganizationsList.js +++ b/server/sonar-web/src/main/js/apps/account/organizations/OrganizationsList.js @@ -19,6 +19,7 @@ */ // @flow import React from 'react'; +import { sortBy } from 'lodash'; import OrganizationCard from './OrganizationCard'; import type { Organization } from '../../../store/organizations/duck'; @@ -29,7 +30,9 @@ type Props = { export default function OrganizationsList(props: Props) { return ( <ul className="account-projects-list"> - {props.organizations.map(organization => ( + {sortBy(props.organizations, organization => + organization.name.toLocaleLowerCase() + ).map(organization => ( <li key={organization.key}> <OrganizationCard organization={organization} /> </li> |