|
@@ -342,15 +342,24 @@
|
|
t.subject_ AS schoolSubject,
|
|
t.subject_ AS schoolSubject,
|
|
|
|
|
|
(SELECT group_concat(p.subject_name_) FROM teacher_subject_price p WHERE find_in_set(t.user_id_,p.teacher_id_)) AS configSubject,
|
|
(SELECT group_concat(p.subject_name_) FROM teacher_subject_price p WHERE find_in_set(t.user_id_,p.teacher_id_)) AS configSubject,
|
|
- sp.subject_id_ AS subjectId,
|
|
|
|
- sp.subject_name_ AS subjectName,
|
|
|
|
- sp.subject_price_ AS subjectPrice,
|
|
|
|
- sp.course_minutes_ AS courseMinutes
|
|
|
|
|
|
+ sp.subjectId AS subjectId,
|
|
|
|
+ sp.subjectName AS subjectName,
|
|
|
|
+ sp.subjectPrice AS subjectPrice,
|
|
|
|
+ sp.courseMinutes AS courseMinutes
|
|
|
|
|
|
FROM teacher t
|
|
FROM teacher t
|
|
LEFT JOIN sys_user u ON t.user_id_ = u.id_
|
|
LEFT JOIN sys_user u ON t.user_id_ = u.id_
|
|
LEFT JOIN teacher_total tt ON t.user_id_=tt.user_id_
|
|
LEFT JOIN teacher_total tt ON t.user_id_=tt.user_id_
|
|
- LEFT JOIN teacher_subject_price sp ON t.user_id_=sp.teacher_id_
|
|
|
|
|
|
+ LEFT JOIN (SELECT
|
|
|
|
+ f.teacher_id_ AS teacherId,
|
|
|
|
+ p.subject_id_ AS subjectId,
|
|
|
|
+ p.subject_name_ AS subjectName,
|
|
|
|
+ p.subject_price_ AS subjectPrice,
|
|
|
|
+ p.course_minutes_ AS courseMinutes
|
|
|
|
+ FROM teacher_free_time f
|
|
|
|
+ LEFT JOIN teacher_subject_price p ON f.id_=p.teacher_free_time_id
|
|
|
|
+ WHERE f.default_flag_=1
|
|
|
|
+ AND p.subject_id_=#{param.subjectId}) sp ON t.user_id_=sp.teacherId
|
|
|
|
|
|
WHERE t.user_id_ IN (SELECT teacher_id_ FROM teacher_free_time GROUP BY teacher_id_)
|
|
WHERE t.user_id_ IN (SELECT teacher_id_ FROM teacher_free_time GROUP BY teacher_id_)
|
|
<if test="param.subjectId !=null">
|
|
<if test="param.subjectId !=null">
|