Merged mward/repo-1844-sortorder (5.2.1) to 5.2.N (5.2.1)

134816 mward: REPO-1844: sort order problems with ID


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@134825 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Matt Ward
2017-01-30 15:43:20 +00:00
parent 04c6028147
commit 86467be9b6
2 changed files with 148 additions and 31 deletions

View File

@@ -83,14 +83,13 @@ public class GroupsImpl implements Groups
{
private static final int MAX_ZONES = 1;
private static final String DISPLAY_NAME = "displayName";
private static final String SHORT_NAME = "shortName";
// private static final String AUTHORITY_NAME = "authorityName";
private static final String AUTHORITY_NAME = "authorityName";
private final static Map<String, String> SORT_PARAMS_TO_NAMES;
static
{
Map<String, String> aMap = new HashMap<>(2);
aMap.put(PARAM_ID, SHORT_NAME);
aMap.put(PARAM_ID, AUTHORITY_NAME);
aMap.put(PARAM_DISPLAY_NAME, DISPLAY_NAME);
SORT_PARAMS_TO_NAMES = Collections.unmodifiableMap(aMap);
@@ -647,9 +646,9 @@ public class GroupsImpl implements Groups
{
v = g.getAuthorityDisplayName();
}
else if (SHORT_NAME.equals(sortBy))
else if (AUTHORITY_NAME.equals(sortBy))
{
v = g.getShortName();
v = g.getAuthorityName();
}
else
{