package org.jeecg.modules.adweb.enquiry.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.adweb.enquiry.dto.param.EffectiveEnquiryParamDto;
import org.jeecg.modules.adweb.enquiry.entity.AdwebSiteBlackEmail;

import java.util.List;
import java.util.Map;

/**
 * @Description: adweb_site_black_email
 * @Author: jeecg-boot
 * @Date: 2023-06-28
 * @Version: V1.0
 */
public interface IAdwebSiteBlackEmailService extends IService<AdwebSiteBlackEmail> {
    /**
     * 根据站点id获取并存取黑名单数据到redis
     */
    void saveRedisSiteBlackEmailBySiteId(Integer siteId, Integer blackOrWhite);

    /**
     * 根据站点id获取对应所有的黑白名单数据
     */
    Map<String, List<String>> getSiteBlackEmailListBySiteId(Integer siteId);

    /**
     * 获取分页列表数据
     *
     * @param page
     * @param enquirySiteBlackEmail
     * @param codeList
     * @return
     */
    IPage<AdwebSiteBlackEmail> pageList(Page<AdwebSiteBlackEmail> page, AdwebSiteBlackEmail enquirySiteBlackEmail, List<String> codeList, String column, String order);

    /**
     * 更改为垃圾询盘处理邮箱黑名单
     *
     * @param effectiveEnquiryParamDto
     */
    void addBlackEmailByContent(EffectiveEnquiryParamDto effectiveEnquiryParamDto);
}
