|
@@ -20,7 +20,28 @@
|
|
|
left join base_grade t4 on t.grade_id=t4.id
|
|
|
left join xjr_user t5 on t.assessment_user_id=t5.id
|
|
|
left join xjr_dictionary_detail t6 on t6.code=t.score_type
|
|
|
- where t.delete_mark=0 and t1.delete_mark=0 and t2.delete_mark=0 and t3.delete_mark=0 and t.status=1;
|
|
|
+ where t.delete_mark=0 and t1.delete_mark=0 and t2.delete_mark=0 and t3.delete_mark=0 and t.status=1
|
|
|
+ <if test="dto.projectIds != null">
|
|
|
+ and t.base_student_assessment_project_id in
|
|
|
+ <foreach item="projectId" index="index" collection="dto.projectIds" open="(" close=")" separator=",">
|
|
|
+ #{projectId}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ <if test="dto.gradeId != null">
|
|
|
+ and t.grade_id = #{dto.gradeId}
|
|
|
+ </if>
|
|
|
+ <if test="dto.semesterId != null">
|
|
|
+ and t.base_semester_id = #{dto.semesterId}
|
|
|
+ </if>
|
|
|
+ <if test="dto.startDate != null and dto.startDate != ''">
|
|
|
+ and t.assessment_date >= #{dto.startDate}
|
|
|
+ </if>
|
|
|
+ <if test="dto.endDate != null and dto.endDate != ''">
|
|
|
+ and t.assessment_date <= #{dto.endDate}
|
|
|
+ </if>
|
|
|
+ <if test="dto.assessmentUserName != null and dto.assessmentUserName != ''">
|
|
|
+ and t5.name like concat('%',#{dto.assessmentUserName},'%')
|
|
|
+ </if>
|
|
|
</select>
|
|
|
|
|
|
<select id="getInfo" resultType="com.xjrsoft.module.student.vo.BaseStudentAssessmentInspectionVo">
|
|
@@ -37,10 +58,12 @@
|
|
|
where t.id=#{id} and t.delete_mark=0 and t1.delete_mark=0 and t2.delete_mark=0 and t3.delete_mark=0 and t.status=1;
|
|
|
</select>
|
|
|
|
|
|
- <select id="getMobilePage" 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 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
|
|
|
+ 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
|
|
@@ -48,7 +71,22 @@
|
|
|
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 ;
|
|
|
+ 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>
|
|
|
|
|
|
<select id="getMobileInfo" resultType="com.xjrsoft.module.student.vo.BaseStudentAssessmentInspectionMobileVo">
|