Browse Source

1、课外训练-教学

Joburgess 5 years ago
parent
commit
086d233505

+ 1 - 1
mec-biz/src/main/resources/config/mybatis/ExtracurricularExercisesReplyMapper.xml

@@ -262,7 +262,7 @@
 				AND is_view_ = #{isView}
 			</if>
 			<if test="search != null">
-				AND (title_ like concat('%',#{search},'%') or u.username_ like concat('%',#{search},'%'))
+				AND (title_ like concat('%',#{search},'%') or u.id_=#{search} or u.username_ like concat('%',#{search},'%'))
 			</if>
 			<if test="submitStartTime != null">
 				AND date(eer.create_time_) &gt;= #{submitStartTime}

+ 3 - 4
mec-biz/src/main/resources/config/mybatis/StudentExtracurricularExercisesSituationMapper.xml

@@ -123,9 +123,8 @@
 		SELECT
 			student_id_,
 			stu.username_ student_name_,
-			tea.real_name_ teacher_name_,
+			MAX(tea.real_name_) teacher_name_,
 			o.name_ organ_name_,
-			MAX( teacher_id_ ) teacher_id_,
 			SUM( expect_exercises_num_ ) expect_exercises_num_,
 			SUM( actual_exercises_num_ ) actual_exercises_num_,
 			SUM( exercises_reply_num_ ) exercises_reply_num_,
@@ -140,7 +139,7 @@
 			sees.monday_ &gt;= #{monday}
 			AND sees.sunday_ &lt;= #{sunday}
 			<if test="search!=null">
-				AND (stu.username_ LIKE CONCAT('%', #{search}, '%') OR tea.username_ LIKE CONCAT('%', #{search}, '%'))
+				AND (stu.id_=#{search} OR stu.username_ LIKE CONCAT('%', #{search}, '%') OR tea.username_ LIKE CONCAT('%', #{search}, '%'))
 			</if>
 			GROUP BY
 			student_id_
@@ -187,7 +186,7 @@
 			sees.monday_ &gt;= #{monday}
 			AND sees.sunday_ &lt;= #{sunday}
 			<if test="search!=null">
-				AND (stu.username_ LIKE CONCAT('%', #{search}, '%') OR tea.username_ LIKE CONCAT('%', #{search}, '%'))
+				AND (stu.id_=#{search} OR stu.username_ LIKE CONCAT('%', #{search}, '%') OR tea.username_ LIKE CONCAT('%', #{search}, '%'))
 			</if>
 			GROUP BY
 			student_id_