package com.gxwebsoft.shop.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.gxwebsoft.common.core.web.PageResult;
import com.gxwebsoft.shop.entity.ViewHistory;
import com.gxwebsoft.shop.param.ViewHistoryParam;

import java.util.List;

/**
 * 浏览历史Service
 *
 * @author 科技小王子
 * @since 2024-11-22 22:13:47
 */
public interface ViewHistoryService extends IService<ViewHistory> {

    /**
     * 分页关联查询
     *
     * @param param 查询参数
     * @return PageResult<ViewHistory>
     */
    PageResult<ViewHistory> pageRel(ViewHistoryParam param);

    /**
     * 关联查询全部
     *
     * @param param 查询参数
     * @return List<ViewHistory>
     */
    List<ViewHistory> listRel(ViewHistoryParam param);

    /**
     * 根据id查询
     *
     * @param id 
     * @return ViewHistory
     */
    ViewHistory getByIdRel(Integer id);

    ViewHistory check(Integer type, Integer pk, Integer userId);

    ViewHistory check(Integer type, Integer pk, String openId);
}
