package rd.dao.mapper.score;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import rd.data.dto.score.CourseScoreInfoDto;
import rd.data.dto.score.StudentScore;
import rd.data.db.table.Score;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface ScoreMapper extends BaseMapper<Score> {
    List<StudentScore> getStudentAllScore(@Param("student") Long student, @Param("term") String term);

    List<CourseScoreInfoDto> getTermCourseAllSelectedStudentScore(@Param("course") Long course,
                                                                  @Param("term") String term
    );

    void insertOrUpdateScore(@Param("score") Score score);

//    void insertOrUpdateScoreBatch(@Param("scores") List<Score> score);
}
