|
@@ -380,16 +380,19 @@
|
|
|
<foreach collection="studentIds" item="studentId" open="(" close=")" separator=",">
|
|
|
#{studentId}
|
|
|
</foreach>
|
|
|
- <if test="query.courseType != null and query.courseType == 'no_course'">
|
|
|
- and mgpscd.sub_course_minutes_ = 0
|
|
|
- </if>
|
|
|
group by user_id_
|
|
|
<if test="query.courseType != null and query.courseType != '' and query.courseType != 'no_course'">
|
|
|
HAVING ${query.courseType} > 0
|
|
|
</if>
|
|
|
- <if test="query.sortField != null">
|
|
|
+ <if test="query.courseType != null and query.courseType == 'no_course'">
|
|
|
+ HAVING SUM(mgpscd.sub_course_minutes_) = 0
|
|
|
+ </if>
|
|
|
+ <if test="query.sortField != null and query.sortField != ''">
|
|
|
order by ${query.sortField} ${query.sortType}
|
|
|
</if>
|
|
|
+ <if test="query.sortField == null or query.sortField == ''">
|
|
|
+ order by user_id_
|
|
|
+ </if>
|
|
|
</select>
|
|
|
|
|
|
<update id="clearRemainCourseMinutesByMusicGroupId">
|