|
@@ -627,8 +627,7 @@
|
|
|
<if test="transactionTeacherId!=null">
|
|
|
LEFT JOIN music_group mg ON cs.music_group_id_=mg.id_
|
|
|
</if>
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL) AND cs.pre_course_flag_ != 1 and cs.tenant_id_ = #{tenantId}
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1 and cs.tenant_id_ = #{tenantId}
|
|
|
<if test="organIds!=null and organIds.size()>0">
|
|
|
AND cs.organ_id_ IN
|
|
|
<foreach collection="organIds" item="organId" separator="," open="(" close=")">
|
|
@@ -668,8 +667,7 @@
|
|
|
<if test="transactionTeacherId!=null">
|
|
|
LEFT JOIN music_group mg ON cs.music_group_id_=mg.id_
|
|
|
</if>
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL) AND cs.pre_course_flag_ != 1 and cs.tenant_id_ = #{tenantId}
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1 and cs.tenant_id_ = #{tenantId}
|
|
|
AND cs.id_ IS NOT NULL
|
|
|
<if test="organIds!=null and organIds.size()>0">
|
|
|
AND cs.organ_id_ IN
|
|
@@ -725,9 +723,8 @@
|
|
|
LEFT JOIN course_schedule_complaints csc ON csc.course_schedule_id_=cssp.course_schedule_id_ AND
|
|
|
csc.user_id_=#{studentId}
|
|
|
LEFT JOIN student_attendance sa ON sa.course_schedule_id_ = cs.id_ AND sa.user_id_=#{studentId}
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
- AND (cs.is_lock_=0 OR cs.is_lock_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
+ AND cs.is_lock_ = 0
|
|
|
AND cs.class_date_ = DATE_FORMAT(#{classDate},'%Y%m%d')
|
|
|
AND cssp.user_id_ = #{studentId} AND cs.pre_course_flag_ != 1
|
|
|
<if test="quitClassGroupIds != null and quitClassGroupIds.size()>0">
|
|
@@ -773,9 +770,7 @@
|
|
|
LEFT JOIN class_group cg ON cs.class_group_id_ = cg.id_
|
|
|
LEFT JOIN school s ON cs.schoole_id_ = s.id_
|
|
|
LEFT JOIN teacher_attendance ta ON cs.id_=ta.course_schedule_id_ AND ta.teacher_id_=#{teacherId}
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
- AND (cs.is_lock_=0 OR cs.is_lock_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.is_lock_ = 0
|
|
|
AND cs.class_date_ = DATE_FORMAT(#{classDate},'%Y%m%d')
|
|
|
<if test="type!=null and type!=''">
|
|
|
AND cs.type_=#{type}
|
|
@@ -811,9 +806,8 @@
|
|
|
LEFT JOIN class_group cg ON cs.class_group_id_ = cg.id_
|
|
|
LEFT JOIN school s ON cs.schoole_id_ = s.id_
|
|
|
LEFT JOIN teacher_attendance ta ON cs.id_=ta.course_schedule_id_ AND ta.teacher_id_=#{teacherId}
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
- AND (cs.is_lock_=0 OR cs.is_lock_ IS NULL) and cs.tenant_id_ = #{tenantId}
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
+ AND cs.is_lock_ = 0 and cs.tenant_id_ = #{tenantId}
|
|
|
<if test="teacherId!=null">
|
|
|
AND cs.actual_teacher_id_=#{teacherId}
|
|
|
</if>
|
|
@@ -865,8 +859,8 @@
|
|
|
LEFT JOIN class_group cg ON cs.class_group_id_ = cg.id_
|
|
|
LEFT JOIN school s ON cs.schoole_id_ = s.id_
|
|
|
LEFT JOIN teacher_attendance ta ON cs.id_ = ta.course_schedule_id_ AND ta.teacher_id_ = #{teacherId}
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
- AND (cs.is_lock_=0 OR cs.is_lock_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
+ AND cs.is_lock_ = 0
|
|
|
AND cs.class_date_ = DATE_FORMAT(#{classDate}, '%Y%m%d')
|
|
|
AND csts.user_id_ = #{teacherId}
|
|
|
AND CONCAT(cs.class_date_, ' ', cs.end_class_time_) < NOW() AND cs.pre_course_flag_ != 1
|
|
@@ -1020,15 +1014,13 @@
|
|
|
course_schedule_teacher_salary csts
|
|
|
LEFT JOIN course_schedule cs ON csts.course_schedule_id_=cs.id_
|
|
|
LEFT JOIN class_group cg ON cs.class_group_id_ = cg.id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
- AND (cs.is_lock_=0 OR cs.is_lock_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.is_lock_ = 0
|
|
|
AND csts.user_id_ = #{teacherId} AND cs.pre_course_flag_ != 1
|
|
|
<if test="month==null">
|
|
|
- AND DATE_FORMAT( NOW(), '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="month!=null">
|
|
|
- AND DATE_FORMAT( #{month}, '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="type!=null and type!=''">
|
|
|
AND cs.type_=#{type}
|
|
@@ -1042,18 +1034,16 @@
|
|
|
FROM
|
|
|
course_schedule cs
|
|
|
LEFT JOIN class_group cg ON cs.class_group_id_ = cg.id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
- AND (cs.is_lock_=0 OR cs.is_lock_ IS NULL)
|
|
|
- AND cg.del_flag_ = 0 and cs.tenant_id_ = #{tenantId}
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.is_lock_ = 0
|
|
|
+ AND cg.del_flag_ = '0' and cs.tenant_id_ = #{tenantId}
|
|
|
<if test="teacherId!=null">
|
|
|
AND cs.actual_teacher_id_=#{teacherId}
|
|
|
</if>
|
|
|
<if test="month==null">
|
|
|
- AND DATE_FORMAT( NOW(), '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="month!=null">
|
|
|
- AND DATE_FORMAT( #{month}, '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="groupId!=null">
|
|
|
AND cs.music_group_id_=#{groupId}
|
|
@@ -1071,17 +1061,15 @@
|
|
|
course_schedule_teacher_salary csts
|
|
|
LEFT JOIN course_schedule cs ON csts.course_schedule_id_=cs.id_
|
|
|
LEFT JOIN class_group cg ON cs.class_group_id_ = cg.id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
- AND (cs.is_lock_=0 OR cs.is_lock_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.is_lock_ = 0
|
|
|
AND CONCAT(cs.class_date_,' ',cs.start_class_time_) < NOW()
|
|
|
AND csts.user_id_ = #{teacherId}
|
|
|
- AND cg.del_flag_ = 0 AND cs.pre_course_flag_ != 1
|
|
|
+ AND cg.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
<if test="month==null">
|
|
|
- AND DATE_FORMAT( NOW(), '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="month!=null">
|
|
|
- AND DATE_FORMAT( #{month}, '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
GROUP BY cs.class_date_
|
|
|
</select>
|
|
@@ -1092,17 +1080,16 @@
|
|
|
FROM
|
|
|
course_schedule cs
|
|
|
LEFT JOIN teacher t ON cs.actual_teacher_id_=t.id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cs.class_group_id_ IN
|
|
|
<foreach collection="classGroupIds" item="classGroupId" separator="," open="(" close=")">
|
|
|
#{classGroupId}
|
|
|
</foreach>
|
|
|
<if test="month==null">
|
|
|
- AND DATE_FORMAT( NOW(), '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="month!=null">
|
|
|
- AND DATE_FORMAT( #{month}, '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="type!=null and type!=''">
|
|
|
AND cs.group_type_=#{type}
|
|
@@ -1119,8 +1106,7 @@
|
|
|
<if test="transactionTeacherId!=null">
|
|
|
LEFT JOIN music_group mg ON cs.music_group_id_=mg.id_
|
|
|
</if>
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL) AND cs.pre_course_flag_ != 1 and cs.tenant_id_ = #{tenantId}
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1 and cs.tenant_id_ = #{tenantId}
|
|
|
<if test="organIds!=null and organIds.size()>0">
|
|
|
AND cs.organ_id_ IN
|
|
|
<foreach collection="organIds" item="organId" separator="," open="(" close=")">
|
|
@@ -1128,10 +1114,10 @@
|
|
|
</foreach>
|
|
|
</if>
|
|
|
<if test="month==null">
|
|
|
- AND DATE_FORMAT( NOW(), '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(CURDATE(),'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="month!=null">
|
|
|
- AND DATE_FORMAT( #{month}, '%Y%m' ) = DATE_FORMAT( cs.class_date_, '%Y%m' )
|
|
|
+ AND cs.class_date_ BETWEEN CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-01 00:00:00') AND CONCAT(DATE_FORMAT(#{month},'%Y-%m'),'-31 23:59:59')
|
|
|
</if>
|
|
|
<if test="type!=null and type!=''">
|
|
|
AND cs.group_type_=#{type}
|
|
@@ -1250,7 +1236,7 @@
|
|
|
SELECT cs.*
|
|
|
FROM class_group cg
|
|
|
LEFT JOIN course_schedule cs ON cg.id_ = cs.class_group_id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cg.music_group_id_ = #{musicGroupId}
|
|
|
</select>
|
|
|
<select id="countClassTimes" resultType="int">
|
|
@@ -1512,8 +1498,7 @@
|
|
|
|
|
|
<sql id="teacherClassCourseScheduleQueryCondition">
|
|
|
<where>
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
- AND (cs.is_lock_=0 OR cs.is_lock_ IS NULL)
|
|
|
+ cs.del_flag_ = '0' AND cs.is_lock_ = 0
|
|
|
AND cs.class_group_id_ = #{classGroupId} AND cs.pre_course_flag_ != 1
|
|
|
<if test="userId != null">
|
|
|
AND csts.user_id_ = #{userId}
|
|
@@ -1651,8 +1636,7 @@
|
|
|
LEFT JOIN sys_user su ON cs.actual_teacher_id_ = su.id_
|
|
|
LEFT JOIN sys_user ssu ON sa.user_id_=ssu.id_
|
|
|
LEFT JOIN school s ON cs.schoole_id_ = s.id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL) AND cs.pre_course_flag_ != 1
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
AND sa.class_group_id_=#{classGroupId}
|
|
|
<if test="userId != null">
|
|
|
AND sa.teacher_id_=#{userId}
|
|
@@ -1685,8 +1669,7 @@
|
|
|
FROM
|
|
|
student_attendance sa
|
|
|
LEFT JOIN course_schedule cs ON sa.course_schedule_id_=cs.id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL) AND cs.pre_course_flag_ != 1
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
AND sa.class_group_id_=#{classGroupId}
|
|
|
<if test="userId != null">
|
|
|
AND sa.teacher_id_=#{userId}
|
|
@@ -1706,7 +1689,7 @@
|
|
|
COUNT(cs.id_) as 'value'
|
|
|
FROM class_group cg
|
|
|
LEFT JOIN course_schedule cs ON cg.id_ = cs.class_group_id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cg.music_group_id_ = #{musicGroupId} AND cs.pre_course_flag_ != 1
|
|
|
GROUP BY cg.id_
|
|
|
</select>
|
|
@@ -1757,8 +1740,7 @@
|
|
|
FROM course_schedule cs
|
|
|
LEFT JOIN class_group cg ON cs.class_group_id_=cg.id_
|
|
|
LEFT JOIN music_group mg ON cs.music_group_id_=mg.id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cs.teacher_id_=#{teacherId} AND cs.pre_course_flag_ != 1
|
|
|
and CONCAT( cs.class_date_, ' ', cs.start_class_time_ ) between #{startTime} and #{endTime}
|
|
|
<if test="type != null">
|
|
@@ -1866,7 +1848,7 @@
|
|
|
SELECT COUNT(csts.course_schedule_id_)
|
|
|
FROM course_schedule_teacher_salary csts
|
|
|
LEFT JOIN course_schedule cs ON csts.course_schedule_id_ = cs.id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND csts.user_id_ = #{teacherId}
|
|
|
AND cs.class_date_ = DATE_FORMAT(#{classDate}, '%Y-%m-%d')
|
|
|
AND DATE_FORMAT(#{startTime}, '%H:%i:%S') <= DATE_FORMAT(cs.end_class_time_, '%H:%i:%S')
|
|
@@ -2152,7 +2134,7 @@
|
|
|
SELECT cs.*
|
|
|
FROM course_schedule_student_payment cssp
|
|
|
LEFT JOIN course_schedule cs ON cssp.course_schedule_id_ = cs.id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cssp.music_group_id_ = #{musicGroupId}
|
|
|
AND cssp.group_type_ = #{groupType}
|
|
|
AND cs.status_ = #{status}
|
|
@@ -2248,7 +2230,7 @@
|
|
|
cs.schoole_id_
|
|
|
FROM course_schedule cs
|
|
|
WHERE cs.class_group_id_ = #{classGroupId}
|
|
|
- AND (cs.del_flag_ = '0' OR cs.del_flag_ IS NULL) AND cs.pre_course_flag_ != 1
|
|
|
+ AND cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
</select>
|
|
|
<select id="countVipGroupCourses" resultType="int">
|
|
|
SELECT count(cs.id_)
|
|
@@ -2426,7 +2408,7 @@
|
|
|
cssp.expect_price_
|
|
|
FROM course_schedule cs
|
|
|
LEFT JOIN course_schedule_student_payment cssp ON cs.id_ = cssp.course_schedule_id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL) AND cs.pre_course_flag_ != 1
|
|
|
+ WHERE cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
<if test="groupType != null">
|
|
|
AND cs.group_type_ = #{groupType, typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}
|
|
|
</if>
|
|
@@ -2454,8 +2436,7 @@
|
|
|
FROM
|
|
|
course_schedule cs
|
|
|
LEFT JOIN course_schedule_student_payment cssp ON cs.id_ = cssp.course_schedule_id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cs.group_type_ = #{groupType, typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}
|
|
|
AND cs.music_group_id_ = #{groupId}
|
|
|
AND cssp.user_id_=#{userId}
|
|
@@ -2482,7 +2463,7 @@
|
|
|
<select id="findSurplusCourseWithGroup" resultMap="CourseSchedule">
|
|
|
SELECT <include refid="resultSql"/>
|
|
|
FROM course_schedule cs
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cs.group_type_ = #{groupType, typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}
|
|
|
AND CONCAT(cs.class_date_, ' ', cs.start_class_time_) > NOW()
|
|
|
AND cs.music_group_id_ = #{groupId}
|
|
@@ -2491,7 +2472,7 @@
|
|
|
<select id="getSurplusCourseWithGroup" resultMap="CourseSchedule">
|
|
|
SELECT <include refid="resultSql"/>
|
|
|
FROM course_schedule cs
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND CONCAT(cs.class_date_, ' ', cs.start_class_time_) > NOW()
|
|
|
AND cs.id_ = #{courseScheduleId}
|
|
|
</select>
|
|
@@ -2746,8 +2727,7 @@
|
|
|
FROM
|
|
|
course_schedule_teacher_salary csts
|
|
|
LEFT JOIN course_schedule cs ON cs.id_ = csts.course_schedule_id_
|
|
|
- WHERE
|
|
|
- (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cs.class_date_ BETWEEN DATE_FORMAT(#{startTime},"%Y-%m-%d") AND DATE_FORMAT(#{endTime},"%Y-%m-%d")
|
|
|
AND csts.user_id_ IN
|
|
|
<foreach collection="userIds" item="userId" open="(" close=")" separator=",">
|
|
@@ -2758,7 +2738,7 @@
|
|
|
SELECT COUNT(1)
|
|
|
FROM course_schedule_teacher_salary csts
|
|
|
LEFT JOIN course_schedule cs ON cs.id_ = csts.course_schedule_id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cs.group_type_ = 'PRACTICE'
|
|
|
AND cs.class_date_ BETWEEN DATE_FORMAT(#{startTime}, "%Y-%m-%d") AND DATE_FORMAT(#{endTime}, "%Y-%m-%d")
|
|
|
AND csts.user_id_ = #{userId}
|
|
@@ -2772,7 +2752,7 @@
|
|
|
cs.group_type_
|
|
|
FROM course_schedule_teacher_salary csts
|
|
|
LEFT JOIN course_schedule cs ON cs.id_ = csts.course_schedule_id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cs.class_date_ BETWEEN DATE_FORMAT(#{startTime}, "%Y-%m-%d") AND DATE_FORMAT(#{endTime}, "%Y-%m-%d")
|
|
|
AND csts.user_id_ = #{userId}
|
|
|
</select>
|
|
@@ -2786,7 +2766,7 @@
|
|
|
cs.group_type_
|
|
|
FROM course_schedule_teacher_salary csts
|
|
|
LEFT JOIN course_schedule cs ON cs.id_ = csts.course_schedule_id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND cs.class_date_ BETWEEN DATE_FORMAT(#{startTime}, "%Y-%m-%d") AND DATE_FORMAT(#{endTime}, "%Y-%m-%d")
|
|
|
AND csts.user_id_ = #{userId}
|
|
|
</select>
|
|
@@ -2841,7 +2821,7 @@
|
|
|
FROM course_schedule_teacher_salary csts
|
|
|
LEFT JOIN course_schedule cs ON csts.course_schedule_id_ = cs.id_
|
|
|
LEFT JOIN class_group cg ON cg.id_ = csts.class_group_id_
|
|
|
- WHERE (cs.del_flag_ != 1 OR cs.del_flag_ IS NULL)
|
|
|
+ WHERE cs.del_flag_ = '0'
|
|
|
AND csts.user_id_ = #{userId}
|
|
|
<if test="groupType != null">
|
|
|
and cs.group_type_ = #{groupType, typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}
|
|
@@ -2955,7 +2935,7 @@
|
|
|
<foreach collection="teacherIds" item="teacherId" open="(" close=")" separator=",">
|
|
|
#{teacherId}
|
|
|
</foreach>
|
|
|
- AND ( cs.del_flag_ != 1 OR cs.del_flag_ IS NULL ) AND cs.pre_course_flag_ != 1
|
|
|
+ AND cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
</select>
|
|
|
<select id="findUserCourses2" resultMap="CourseSchedule">
|
|
|
SELECT
|
|
@@ -2978,7 +2958,7 @@
|
|
|
<foreach collection="teacherIds" item="teacherId" open="(" close=")" separator=",">
|
|
|
#{teacherId}
|
|
|
</foreach>
|
|
|
- AND ( cs.del_flag_ != 1 OR cs.del_flag_ IS NULL ) AND cs.pre_course_flag_ != 1
|
|
|
+ AND cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
</select>
|
|
|
<select id="findUserCourses3" resultMap="CourseSchedule">
|
|
|
SELECT
|
|
@@ -3000,7 +2980,7 @@
|
|
|
<foreach collection="teacherIds" item="teacherId" open="(" close=")" separator=",">
|
|
|
#{teacherId}
|
|
|
</foreach>
|
|
|
- AND ( cs.del_flag_ != 1 OR cs.del_flag_ IS NULL ) AND cs.pre_course_flag_ != 1
|
|
|
+ AND cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
</select>
|
|
|
<select id="findUserCoursesWithPay" resultMap="CourseSchedule">
|
|
|
SELECT
|
|
@@ -3023,7 +3003,7 @@
|
|
|
<foreach collection="teacherIds" item="teacherId" open="(" close=")" separator=",">
|
|
|
#{teacherId}
|
|
|
</foreach>
|
|
|
- AND ( cs.del_flag_ != 1 OR cs.del_flag_ IS NULL )
|
|
|
+ AND cs.del_flag_ = '0'
|
|
|
</select>
|
|
|
|
|
|
<select id="queryTeacherName" resultType="java.util.Map">
|
|
@@ -3075,7 +3055,7 @@
|
|
|
<foreach collection="classGroupIds" item="classGroupId" open="(" close=")" separator=",">
|
|
|
#{classGroupId}
|
|
|
</foreach>
|
|
|
- AND ( cs.del_flag_ != 1 OR cs.del_flag_ IS NULL ) AND cs.pre_course_flag_ != 1
|
|
|
+ AND cs.del_flag_ = '0' AND cs.pre_course_flag_ != 1
|
|
|
ORDER BY start_class_time_
|
|
|
</select>
|
|
|
|