修改排序
This commit is contained in:
@ -53,9 +53,9 @@ public class EventStyleServiceImpl extends ServiceImpl<EventStyleMapper, EventSt
|
||||
query.orderByDesc(EventStyle::getCreateTime);
|
||||
List<EventStyle> list;
|
||||
if ("banner".equals(type)) {
|
||||
query.eq(EventStyle::getBanner, "1").eq(EventStyle::getStatus, "1").orderByAsc(EventStyle::getSort);
|
||||
query.eq(EventStyle::getCategory, "1").eq(EventStyle::getStatus, "1").orderByAsc(EventStyle::getSort);
|
||||
} else {
|
||||
query.eq(EventStyle::getBanner, "0").eq(EventStyle::getStatus, "1").orderByAsc(EventStyle::getSort);
|
||||
query.eq(EventStyle::getCategory, "2").eq(EventStyle::getStatus, "1").orderByAsc(EventStyle::getSort);
|
||||
}
|
||||
query.ne(EventStyle::getDeleteFlag, "1");
|
||||
list = this.list(query);
|
||||
@ -154,7 +154,7 @@ public class EventStyleServiceImpl extends ServiceImpl<EventStyleMapper, EventSt
|
||||
.sendTime(s.getSendTime())
|
||||
.build()));
|
||||
}
|
||||
List<EventMaintainOutVO> collect = outVOList.stream().sorted(Comparator.comparing(EventMaintainOutVO::getSendTime, Comparator.nullsLast(LocalDateTime::compareTo)).reversed()).collect(Collectors.toList());
|
||||
List<EventMaintainOutVO> collect = outVOList.stream().sorted(Comparator.comparing(EventMaintainOutVO::getCreateTime, Comparator.nullsLast(LocalDateTime::compareTo)).reversed()).collect(Collectors.toList());
|
||||
IPage<EventMaintainOutVO> iPage = new Page<>();
|
||||
iPage.setTotal(stylePage.getTotal());
|
||||
iPage.setPages(stylePage.getPages());
|
||||
|
Reference in New Issue
Block a user