Commit c8f99abc authored by Mindfaker's avatar Mindfaker

init data

parent 68cdb58f
......@@ -203,6 +203,14 @@ public interface SpecialSqlMapper {
)
Map selectUnfinishLessonCount(@Param("userId") Integer userId);
/**
* 随机选择一个的学生
* @param classId
* @return
*/
@Select("SELECT * FROM (SELECT * FROM student_info WHERE deleted = FALSE AND class_id = ${classId}) a1 LEFT JOIN ( SELECT (RAND() * max(id) ) as nid FROM student_info WHERE deleted = FALSE AND class_id = ${classId}) a2 ON a1.id > a2.nid LIMIT 1")
Map<String, Object> selectRandomStudentInfo(@Param("classId") Integer classId);
@Select("<script> " +
"SELECT count(*) as count_info FROM user_reduce_info WHERE deleted = FALSE" +
"<if test='lesson_average_point != null'> AND lesson_average_point &gt; ${lesson_average_point} </if>" +
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment