|
|
@ -227,9 +227,10 @@ public class RecordService implements IRecordService{ |
|
|
prev = cur; |
|
|
prev = cur; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
if (types.length > 1) { |
|
|
if (types.length > 1 && CollectionUtil.isNotEmpty(records)) { |
|
|
log.info("重新排序"); |
|
|
log.info("重新排序"); |
|
|
Collections.sort(records, (o1, o2) ->{ |
|
|
Collections.sort(records, (o1, o2) ->{ |
|
|
|
|
|
log.info("o1:{},o2:{}",o1,o2); |
|
|
if (o1 == null || o1.getTime() == null) { |
|
|
if (o1 == null || o1.getTime() == null) { |
|
|
if (o2 == null || o2.getTime() == null) { |
|
|
if (o2 == null || o2.getTime() == null) { |
|
|
return 0; |
|
|
return 0; |
|
|
@ -239,7 +240,7 @@ public class RecordService implements IRecordService{ |
|
|
if (o2 == null || o2.getTime() == null) { |
|
|
if (o2 == null || o2.getTime() == null) { |
|
|
return -1; |
|
|
return -1; |
|
|
} |
|
|
} |
|
|
return (int) (o1.getTime() - o2.getTime()); |
|
|
return o1.getTime() - o2.getTime() > 0 ? 1 : -1; |
|
|
} ); |
|
|
} ); |
|
|
} |
|
|
} |
|
|
return records; |
|
|
return records; |
|
|
|