mirror of
https://gitee.com/huangge1199_admin/vue-pro.git
synced 2024-11-22 15:21:53 +08:00
【功能优化】订单日志根据创建时间倒序
This commit is contained in:
parent
94effa87a3
commit
427cf8e4f6
@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.trade.dal.mysql.order;
|
||||
|
||||
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||
import cn.iocoder.yudao.module.trade.dal.dataobject.order.TradeOrderLogDO;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
@ -10,7 +11,10 @@ import java.util.List;
|
||||
public interface TradeOrderLogMapper extends BaseMapperX<TradeOrderLogDO> {
|
||||
|
||||
default List<TradeOrderLogDO> selectListByOrderId(Long orderId) {
|
||||
return selectList(TradeOrderLogDO::getOrderId, orderId);
|
||||
LambdaQueryWrapper<TradeOrderLogDO> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.eq(TradeOrderLogDO::getOrderId, orderId);
|
||||
queryWrapper.orderByDesc(TradeOrderLogDO::getCreateTime);
|
||||
return selectList(queryWrapper);
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user