package com.fdkankan.ucenter.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.fdkankan.ucenter.entity.OrderItem;
import com.fdkankan.ucenter.mapper.IOrderItemMapper;
import com.fdkankan.ucenter.service.IOrderItemService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 订单项表 服务实现类
 * </p>
 *
 * @author 
 * @since 2022-07-13
 */
@Service
public class OrderItemServiceImpl extends ServiceImpl<IOrderItemMapper, OrderItem> implements IOrderItemService {

    @Override
    public List<OrderItem> getByOrderId(Long orderId) {
        LambdaQueryWrapper<OrderItem> wrapper = new LambdaQueryWrapper<>();
        wrapper.eq(OrderItem::getOrderId,orderId);
        return this.list(wrapper);
    }
}
