package com.ruoyi.mall.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.mall.domain.MemberCart;
import com.ruoyi.mall.domain.query.MemberCartQuery;
import com.ruoyi.mall.domain.vo.MemberCartVO;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDateTime;
import java.util.List;

/**
 * 购物车Mapper接口
 *
 * @author zcc
 */
public interface MemberCartMapper extends BaseMapper<MemberCart> {
    /**
     * 查询购物车列表
     *
     * @param memberCart 购物车
     * @return 购物车集合
     */
    List<MemberCart> selectByEntity(MemberCart memberCart);

    /**
     *
     */
    List<MemberCartVO> selectByPage(MemberCartQuery query);
    List<MemberCartVO> getList(@Param("userId") Long userId,@Param("storeId") Long storeId);

    int statAddCount(@Param("startTime") LocalDateTime startTime, @Param("endTime") LocalDateTime endTime);
}
