package com.ruoyi.web.work.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.web.work.domain.Banner;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @author lsw
 * @date 2024-04-15
 */
public interface BannerMapper extends BaseMapper<Banner> {
    List<Banner> selectList(Banner banner);

    @Select("SELECT * FROM tb_banner WHERE state=0 AND type=#{type} ORDER BY order_num ASC LIMIT 5")
    List<Banner> homeList(@Param("type") Integer type);
}
