|
@@ -76,6 +76,35 @@
|
76
|
76
|
where c.schoolid=#{schoolid} and c.year=#{year} and c.classstate=1 and u.usertype=1 and u.userstate=1 and c.classtype in (1,2)
|
77
|
77
|
order by c.gradeid,c.classtype,c.classorder,s.subjectorder,convert(u.username using gbk)
|
78
|
78
|
</select>
|
|
79
|
+ <!--集团校教师-->
|
|
80
|
+ <resultMap id="jtTeacherResult" type="java.util.Map">
|
|
81
|
+ <result property="schoolid" column="schoolid"/>
|
|
82
|
+ <result property="schoolname" column="schoolname"/>
|
|
83
|
+ <collection property="grades" ofType="java.util.Map" javaType="java.util.List">
|
|
84
|
+ <result property="gradeid" column="gradeid"/>
|
|
85
|
+ <collection property="subjects" ofType="java.util.Map" javaType="java.util.List">
|
|
86
|
+ <result property="subjectid" column="subjectid"/>
|
|
87
|
+ <result property="subjectname" column="subjectname"/>
|
|
88
|
+ <collection property="teachers" ofType="java.util.Map" javaType="java.util.List">
|
|
89
|
+ <result property="teacherid" column="teacherid"/>
|
|
90
|
+ <result property="teachername" column="teachername"/>
|
|
91
|
+ </collection>
|
|
92
|
+ </collection>
|
|
93
|
+ </collection>
|
|
94
|
+ </resultMap>
|
|
95
|
+ <select id="listJtTeacher" resultMap="jtTeacherResult">
|
|
96
|
+ select s1.schoolid,s1.schoolname,c.gradeid,s.subjectid,s.subjectname
|
|
97
|
+ ,u.userid as teacherid,u.username as teachername
|
|
98
|
+ from t_school_friend sf left join t_school s1 on sf.fschoolid=s1.schoolid
|
|
99
|
+ left join t_class c on s1.schoolid=c.schoolid
|
|
100
|
+ left join t_teacher_powersb ts on c.schoolid=ts.schoolid
|
|
101
|
+ left join t_subject s on ts.subjectid=s.subjectid
|
|
102
|
+ left join t_class_teacher ct on c.classid=ct.classid and ts.teacherid=ct.teacherid
|
|
103
|
+ left join t_user u on ct.teacherid=u.userid
|
|
104
|
+ where sf.schoolid=#{schoolid} and c.year=#{year} and c.classstate=1 and u.usertype=1 and u.userstate=1 and c.classtype in (1,2)
|
|
105
|
+ group by u.userid
|
|
106
|
+ order by s.schoolid,c.gradeid,c.classtype,c.classorder,s.subjectorder,convert(u.username using gbk)
|
|
107
|
+ </select>
|
79
|
108
|
|
80
|
109
|
<!--集团校班级-->
|
81
|
110
|
<resultMap id="listJtClassMap" type="java.util.Map">
|