package org.jeecg.modules.bytedance.advertise.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.bytedance.advertise.entity.ByteDanceCreativeWordPackage;
import org.jeecg.modules.bytedance.advertise.entity.ByteDanceGeneralCopywriter;

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

/**
 * 通用文案库
 * @author jeecg-boot
 * 2021-05-28
 * @version V1.0
 */
public interface ByteDanceGeneralCopywriterMapper extends BaseMapper<ByteDanceGeneralCopywriter> {
    List<Map<String,Object>> selectGeneralCopywriterReport(List<String> accountIds, String keyWord, Integer status, String startTime, String endTime);

    ByteDanceCreativeWordPackage selectCreativeWordPackageByName(String name);

    List<ByteDanceGeneralCopywriter> getRandThree(@Param(value = "accountId") Long accountId);

    /**
     * 查询账户 通用文案 数量
     * @param accountId 账户di
     * @param copywritingNumber 文案数量
     * @return
     */
    List<ByteDanceGeneralCopywriter> getRandTen(@Param(value = "accountId") Long accountId,@Param("copywritingNumber")Integer copywritingNumber);

    List<ByteDanceGeneralCopywriter> selectAllDataByTextCopywriter(@Param(value = "textCopywriter") String textCopywriter);
}
