package com.mcwl.communityCenter.mapper;

import com.baomidou.mybatisplus.annotation.InterceptorIgnore;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.mcwl.communityCenter.domain.Community;
import com.mcwl.communityCenter.domain.CommunityFile;
import com.mcwl.communityCenter.domain.dto.CommunityFilePageListRes;
import com.mcwl.communityCenter.domain.vo.CommunityFileVo;
import org.apache.ibatis.annotations.MapKey;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import javax.validation.constraints.NotNull;
import java.util.List;
import java.util.Map;

@Mapper
public interface CommunityFileMapper extends BaseMapper<CommunityFile> {

    @InterceptorIgnore(tenantLine = "true")
    List<CommunityFileVo> getCommunityFileList(Page<CommunityFile> page, @Param("communityFilePageListRes") CommunityFilePageListRes communityFilePageListRes);

    @InterceptorIgnore(tenantLine = "true")
    CommunityFile selectCommunityFile(@Param("tenantId") Long tenantId,
                                      @Param("communityId") Long communityId,
                                      @Param("fileId") Long fileId);
}
