package com.xunmei.core.resumption.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xunmei.core.resumption.domain.AppRulePoint;
import com.xunmei.core.resumption.domain.Resumption;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

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

@Mapper
public interface ResumptionMapper extends BaseMapper<Resumption> {

    List<Map<String, Object>> findDayTaskList(@Param("year") int year, @Param("quarter") int quarter, @Param("dateTime") String dateTime, @Param("roleId") Long roleId, @Param("orgid") Long orgid);

    List<Map<String, Object>> findMonthTaskList(@Param("year")int year, @Param("month")int month, @Param("type")int type, @Param("roleId")Long roleId,@Param("orgid") Long orgid, @Param("quarter")int quarter);

    List<Map<String, Object>> findYearTaskList(@Param("year")int year,@Param("type") int type,@Param("roleId") Long roleId, @Param("orgid")Long orgid,@Param("quarter") int quarter);

    Resumption findOneByTaskIdAndDate(@Param("taskId")String taskId,@Param("year") int year, @Param("quarter")int quarter);
    List<Map<String, Object>> findOneByTaskId(@Param("taskId")String taskId,@Param("year")int year,@Param("quarter")int quarter);

    void updateResumption(@Param("resumption") Resumption resumption);
}
