|
@@ -65,48 +65,18 @@
|
|
|
AND t.id = #{id}
|
|
|
</select>
|
|
|
|
|
|
- <select id="getMobilePage" parameterType="com.xjrsoft.module.student.dto.BaseStudentAssessmentInspectionMobilePageDto" resultType="com.xjrsoft.module.student.vo.BaseStudentAssessmentInspectionMobilePageVo">
|
|
|
- select t.id,t1.assessment_date,t2.name as assessment_category_name,t3.name as assessment_project_name,t5.name as
|
|
|
- assessment_class_name,t1.reason,t1.score,t1.score_type,t4.name as score_type_cn,
|
|
|
- (
|
|
|
- SELECT count(*) FROM base_student_assessment_student_relation WHERE base_student_assessment_inspection_id =
|
|
|
- t1.id and class_id=t.class_id
|
|
|
- ) as student_count
|
|
|
- from base_student_assessment_class_relation t
|
|
|
- left join base_student_assessment_inspection t1 on t1.id=t.base_student_assessment_inspection_id
|
|
|
- left join base_student_assessment_category t2 on (t2.id = t1.base_student_assessment_category_id)
|
|
|
- left join base_student_assessment_project t3 on (t3.id = t1.base_student_assessment_project_id)
|
|
|
- left join xjr_dictionary_detail t4 on t4.code=t1.score_type
|
|
|
- left join base_class t5 on t5.id=t.class_id
|
|
|
- where t1.delete_mark=0 and t1.status=1 and t.class_id in
|
|
|
- <foreach item="classId" index="index" collection="dto.classIds" open="(" close=")" separator=",">
|
|
|
- #{classId}
|
|
|
- </foreach>
|
|
|
- <if test="dto.projectIds != null">
|
|
|
- and t1.base_student_assessment_project_id in
|
|
|
- <foreach item="projectId" index="index" collection="dto.projectIds" open="(" close=")" separator=",">
|
|
|
- #{projectId}
|
|
|
- </foreach>
|
|
|
- </if>
|
|
|
- <if test="dto.startDate != null and dto.startDate != ''">
|
|
|
- and t1.assessment_date >= #{dto.startDate}
|
|
|
- </if>
|
|
|
- <if test="dto.endDate != null and dto.endDate != ''">
|
|
|
- and t1.assessment_date <= #{dto.endDate}
|
|
|
- </if>
|
|
|
+ <select id="getMobilePage" parameterType="com.xjrsoft.module.student.dto.BaseStudentBehaviorManageMobilePageDto" resultType="com.xjrsoft.module.student.vo.BaseStudentBehaviorManageMobilePageVo">
|
|
|
+ SELECT t1.sort_code,t1.name,t1.class_name,t.assessment_date,
|
|
|
+ t3.name AS categoryName,t4.name AS projectName,t.score,t4.score_type FROM base_student_behavior_manage t
|
|
|
+ INNER JOIN base_student_behavior_student_relation t1 ON t1.base_student_behavior_manage_id = t.id
|
|
|
+ LEFT JOIN xjr_user t2 ON t2.id = t.assessment_user_id
|
|
|
+ LEFT JOIN base_student_behavior_category t3 ON t3.id = t.base_student_behavior_category_id
|
|
|
+ LEFT JOIN base_student_behavior_project t4 ON t4.id = t.base_student_behavior_project_id
|
|
|
+ LEFT JOIN base_student_school_roll t5 ON t1.user_id = t5.user_id
|
|
|
+ WHERE t.status = 1 AND t.delete_mark = 0
|
|
|
+ AND t5.class_id IN (
|
|
|
+ SELECT id FROM base_class WHERE teacher_id = #{dto.teacherId}
|
|
|
+ )
|
|
|
</select>
|
|
|
|
|
|
- <select id="getMobileInfo" resultType="com.xjrsoft.module.student.vo.BaseStudentAssessmentInspectionMobileVo">
|
|
|
- select t.id,t.class_id,t.base_student_assessment_inspection_id,t1.score,t5.name as assessment_class_name,t2.name as assessment_category_name,t3.name as assessment_project_name,t1.assessment_date,t1.reason,
|
|
|
- t6.name as assessment_user_name,t7.name as create_user_name,t1.create_date,t1.file_id,t1.score_type,t4.name as score_type_cn
|
|
|
- from base_student_assessment_class_relation t
|
|
|
- left join base_student_assessment_inspection t1 on t1.id=t.base_student_assessment_inspection_id
|
|
|
- left join base_student_assessment_category t2 on (t2.id = t1.base_student_assessment_category_id)
|
|
|
- left join base_student_assessment_project t3 on (t3.id = t1.base_student_assessment_project_id)
|
|
|
- left join xjr_dictionary_detail t4 on t4.code=t1.score_type
|
|
|
- left join base_class t5 on t5.id=t.class_id
|
|
|
- left join xjr_user t6 on t1.assessment_user_id=t6.id
|
|
|
- left join xjr_user t7 on t1.create_user_id=t7.id
|
|
|
- where t.id=#{id};
|
|
|
- </select>
|
|
|
</mapper>
|