Fixed sorting folders

pull/156/head
M66B 6 years ago
parent 7c304c96b2
commit 106f14b39c

@ -74,11 +74,17 @@ public class TupleFolderEx extends EntityFolder implements Serializable {
else if (f2.accountName == null) else if (f2.accountName == null)
return -1; return -1;
int o = Integer.compare( int fo = Integer.compare(
f1.order == null ? -1 : f1.order,
f2.order == null ? -1 : f2.order);
if (fo != 0)
return fo;
int ao = Integer.compare(
f1.accountOrder == null ? -1 : f1.accountOrder, f1.accountOrder == null ? -1 : f1.accountOrder,
f2.accountOrder == null ? -1 : f2.accountOrder); f2.accountOrder == null ? -1 : f2.accountOrder);
if (o != 0) if (ao != 0)
return o; return ao;
int a = collator.compare(f1.accountName, f2.accountName); int a = collator.compare(f1.accountName, f2.accountName);
if (a != 0) if (a != 0)

@ -54,11 +54,17 @@ public class TupleFolderNav extends EntityFolder implements Serializable {
else if (f2.accountName == null) else if (f2.accountName == null)
return -1; return -1;
int o = Integer.compare( int fo = Integer.compare(
f1.order == null ? -1 : f1.order,
f2.order == null ? -1 : f2.order);
if (fo != 0)
return fo;
int ao = Integer.compare(
f1.accountOrder == null ? -1 : f1.accountOrder, f1.accountOrder == null ? -1 : f1.accountOrder,
f2.accountOrder == null ? -1 : f2.accountOrder); f2.accountOrder == null ? -1 : f2.accountOrder);
if (o != 0) if (ao != 0)
return o; return ao;
int a = collator.compare(f1.accountName, f2.accountName); int a = collator.compare(f1.accountName, f2.accountName);
if (a != 0) if (a != 0)

@ -55,11 +55,17 @@ public class TupleFolderSort extends EntityFolder {
else if (f2.accountName == null) else if (f2.accountName == null)
return -1; return -1;
int o = Integer.compare( int fo = Integer.compare(
f1.order == null ? -1 : f1.order,
f2.order == null ? -1 : f2.order);
if (fo != 0)
return fo;
int ao = Integer.compare(
f1.accountOrder == null ? -1 : f1.accountOrder, f1.accountOrder == null ? -1 : f1.accountOrder,
f2.accountOrder == null ? -1 : f2.accountOrder); f2.accountOrder == null ? -1 : f2.accountOrder);
if (o != 0) if (ao != 0)
return o; return ao;
int a = collator.compare(f1.accountName, f2.accountName); int a = collator.compare(f1.accountName, f2.accountName);
if (a != 0) if (a != 0)

Loading…
Cancel
Save