package com.xxl.job.executor.report.mapper;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xxl.job.executor.report.entity.KuaishouReportDailyAccount;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface KuaishouReportDailyAccountMapper extends BaseMapper<KuaishouReportDailyAccount> {

    void loadAccountDailyReport(@Param("accountId") Long accountId, @Param("localPath") String localPath);

    void insertSelective(KuaishouReportDailyAccount dailyAccount);

    List<JSONObject> selectCost(@Param("accountId") Long accountId, @Param("startDate") String startDate, @Param("endDate") String endDate);

    List<Long> queryProjectMemberByUserId(@Param("userId") String userId, @Param("mediaIds") List<Long> mediaIds);

    List<Long> queryProjectInfoBySaleId(@Param("userId") String userId, @Param("mediaIds") List<Long> mediaIds);

    List<Long> queryProjectMemberByAdmins(@Param("mediaIds") List<Long> mediaIds);

    List<Long> getUserProjectAccountIds(@Param("userId") String userId, @Param("yn") Integer yn);

    List<Long> getUserProjectAccountIdsByAdmin(@Param("yn") Integer yn);

    List<Long> getSaleProjectAccountIds(@Param("userId") String userId, @Param("yn") Integer yn);

}
