package com.qxgmat.data.relation;

import com.qxgmat.data.dao.entity.UserReport;
import com.qxgmat.data.relation.entity.UserReportLimitRelation;
import com.qxgmat.data.relation.entity.UserStudyStatRelation;
import org.apache.ibatis.annotations.Param;

import java.util.Collection;
import java.util.List;

/**
 * Created by gaojie on 2017/11/9.
 */
public interface UserReportRelationMapper {
    List<UserReport> listFinishLast(
            @Param("paperIds") Collection paperIds,
            @Param("startTime") String startTime,
            @Param("endTime") String endTime
    );

    List<UserReport> listLast(
            @Param("paperIds") Collection paperIds
    );

    void accumulation(
            @Param("id") Number reportId,
            @Param("number") Integer number,
            @Param("time") Integer time,
            @Param("current") Integer current
    );

    List<UserReportLimitRelation> statLimit(
            @Param("module") String module,
            @Param("moduleId") Integer moduleId
    );

    List<UserStudyStatRelation> statByModule(
            @Param("userId") Integer userId,
            @Param("module") String module,
            @Param("startTime") String startTime,
            @Param("endTime") String endTime
    );
}
