|
@@ -673,6 +673,7 @@
|
|
LEFT JOIN course_group g ON p.course_group_id_=g.id_
|
|
LEFT JOIN course_group g ON p.course_group_id_=g.id_
|
|
WHERE p.user_id_=#{studentId}
|
|
WHERE p.user_id_=#{studentId}
|
|
AND s.status_ IN ('ING','NOT_START') and g.status_='ING'
|
|
AND s.status_ IN ('ING','NOT_START') and g.status_='ING'
|
|
|
|
+ and date_format(s.class_date_,'%Y-%m-%d') = date_format(now(),'%Y-%m-%d')
|
|
ORDER BY ABS(NOW() - s.start_time_) ASC
|
|
ORDER BY ABS(NOW() - s.start_time_) ASC
|
|
limit 1
|
|
limit 1
|
|
</select>
|
|
</select>
|
|
@@ -696,6 +697,7 @@
|
|
WHERE s.teacher_id_=#{teacherId}
|
|
WHERE s.teacher_id_=#{teacherId}
|
|
AND s.type_ IN ('PRACTICE','VIP')
|
|
AND s.type_ IN ('PRACTICE','VIP')
|
|
AND s.status_ IN ('ING','NOT_START') and g.status_='ING'
|
|
AND s.status_ IN ('ING','NOT_START') and g.status_='ING'
|
|
|
|
+ and date_format(s.class_date_,'%Y-%m-%d') = date_format(now(),'%Y-%m-%d')
|
|
ORDER BY ABS(NOW() - s.start_time_) ASC
|
|
ORDER BY ABS(NOW() - s.start_time_) ASC
|
|
limit 1
|
|
limit 1
|
|
</select>
|
|
</select>
|
|
@@ -718,6 +720,7 @@
|
|
WHERE s.teacher_id_=#{teacherId}
|
|
WHERE s.teacher_id_=#{teacherId}
|
|
AND s.type_ IN ('LIVE','PIANO_ROOM_CLASS')
|
|
AND s.type_ IN ('LIVE','PIANO_ROOM_CLASS')
|
|
AND s.status_ IN ('ING','NOT_START') and g.status_='ING'
|
|
AND s.status_ IN ('ING','NOT_START') and g.status_='ING'
|
|
|
|
+ and date_format(s.class_date_,'%Y-%m-%d') = date_format(now(),'%Y-%m-%d')
|
|
ORDER BY ABS(NOW() - s.start_time_) ASC
|
|
ORDER BY ABS(NOW() - s.start_time_) ASC
|
|
limit 1
|
|
limit 1
|
|
</select>
|
|
</select>
|