|
@@ -19,6 +19,10 @@
|
|
|
<result column="phone_" jdbcType="VARCHAR" property="phone"/>
|
|
|
<result column="organ_name_" jdbcType="VARCHAR" property="organName"/>
|
|
|
<result column="month_str_" jdbcType="VARCHAR" property="monthStr"/>
|
|
|
+ <collection property="subjectList" ofType="com.ym.mec.biz.dal.entity.Subject">
|
|
|
+ <result column="subject_id" property="id"/>
|
|
|
+ <result column="subject_name" property="name"/>
|
|
|
+ </collection>
|
|
|
</resultMap>
|
|
|
<insert id="insert" parameterType="com.ym.mec.biz.dal.entity.TeacherCourseStatistics" useGeneratedKeys="true"
|
|
|
keyColumn="id" keyProperty="id">
|
|
@@ -68,11 +72,12 @@
|
|
|
GROUP BY csts.user_id_, csts.group_type_;
|
|
|
</select>
|
|
|
|
|
|
- <!-- 分页查询 -->
|
|
|
<select id="queryPage" resultMap="TeacherCourseStatistics" parameterType="map">
|
|
|
- SELECT tcs.*,u.real_name_,u.phone_,o.name_ organ_name_,DATE_FORMAT(tcs.month_,'%Y年%m月') month_str_ FROM teacher_course_statistics tcs
|
|
|
+ SELECT tcs.*,u.real_name_,u.phone_,o.name_ organ_name_,DATE_FORMAT(tcs.month_,'%Y年%m月') month_str_,
|
|
|
+ s.id_ subject_id,s.name_ subject_name FROM teacher_course_statistics tcs
|
|
|
left join sys_user u on tcs.user_id_ = u.id_
|
|
|
left join organization o on tcs.organ_id_ = o.id_
|
|
|
+ LEFT JOIN subject s ON FIND_IN_SET(s.id_,tcs.subject_id_list_)
|
|
|
<include refid="queryParams"/>
|
|
|
<include refid="global.limit"/>
|
|
|
</select>
|