package cn.com.ctop.toutiao.modules.material.mapper;

import cn.com.ctop.toutiao.modules.material.entity.FirstDeliveryValidMaterials;
import cn.com.ctop.toutiao.modules.material.entity.FirstDeliveryValidRatio;
import com.alibaba.fastjson.JSONObject;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface FirstDeliveryValidMapper {

    void delMaterials(@Param("deliveryYear") String deliveryYear, @Param("deliveryMonth") String deliveryMonth);

    void replaceBatchMaterials(@Param("list") List<FirstDeliveryValidMaterials> list);

    void delRatio(@Param("deliveryYear") String deliveryYear, @Param("deliveryMonth") String deliveryMonth);

    void replaceBatchRatio(@Param("list") List<FirstDeliveryValidRatio> materials);

    List<JSONObject> projectData(@Param("year") String year, @Param("month") String month);

    Integer projectDataTotal(@Param("year") String year, @Param("month") String month);

    Integer getTotalDataSum(@Param("year") String year, @Param("month") String month);

    List<JSONObject> getTotalData(String year, String month);

    void replaceEtl();

    List<JSONObject> getDataForProject(@Param("year") String year,@Param("month") String month);


    Integer getDesignDataTotal(@Param("year") String year, @Param("month") String month, @Param("designRole") Integer designRole);

    List<JSONObject> getDesignData(@Param("year") String year, @Param("month") String month, @Param("designRole") Integer designRole);
    List<JSONObject> getDataForUserType(@Param("year") String year,@Param("month") String month,@Param("userType") String userType);
}
