package com.yonge.cooleshow.bbs.dao;

import java.util.List;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.yonge.cooleshow.bbs.dto.search.BbsReplySearch;
import com.yonge.cooleshow.bbs.vo.BbsReplyVo;
import org.apache.ibatis.annotations.Param;
import com.yonge.cooleshow.bbs.entity.BbsArticle;
import com.yonge.cooleshow.bbs.vo.BbsArticleVo;
import com.yonge.cooleshow.bbs.dto.search.BbsArticleSearch;

public interface BbsArticleDao extends BaseMapper<BbsArticle> {
    /**
     * 发布文章
     *
     * @param bbsArticle
     */
    void addArticle(BbsArticle bbsArticle);

    /**
     * 删除文章
     *
     * @param list
     */
    void deleteArticle(List<Long> list);

    /**
     * 分页查询
     *
     * @author liweifan
     * @date 2022-06-09 17:27:11
     * @return: com.yonge.cooleshow.bbs.vo.BbsArticleVo
     */
    List<BbsArticleVo> selectPage(@Param("page") IPage page, @Param("param") BbsArticleSearch bbsArticle);

    /**
     * 查询文章详情
     * @param articleId
     * @return
     */
    BbsArticleVo articleInfo(Long articleId);

    List<BbsReplyVo> articleReply(@Param("page")IPage<BbsReplyVo> page,@Param("param") BbsReplySearch query);
}