package com.jwipc.shopping.service.impl;

import com.jwipc.shopping.entity.ShoppingCartInfo;
import com.jwipc.shopping.mapper.ShoppingCartInfoMapper;
import com.jwipc.shopping.model.po.ShoppingCartInfoPO;
import com.jwipc.shopping.model.vo.CartPurchaseDTO;
import com.jwipc.shopping.service.IShoppingCartInfoService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 商城购物车商品信息 服务实现类
 * </p>
 *
 * @author zx
 * @since 2024-03-14
 */
@Service
public class ShoppingCartInfoServiceImpl extends ServiceImpl<ShoppingCartInfoMapper, ShoppingCartInfo> implements IShoppingCartInfoService {

    @Override
    public List<ShoppingCartInfoPO> getList(Long cartId) {
        return baseMapper.getList(cartId);
    }

    @Override
    public List<ShoppingCartInfoPO> findByCartId(Long cartId) {
        return baseMapper.findByCartId(cartId);
    }

    @Override
    public List<CartPurchaseDTO> getByCartId(Long id) {
        return baseMapper.getByCartId(id);
    }

    @Override
    public List<ShoppingCartInfoPO> getShoppingCartInfoListPO(String billNo, String itemNo) {
        return baseMapper.getShoppingCartInfoListPO(billNo,itemNo);
    }
}
