@ -64,21 +62,30 @@ public interface ExperimentallearningMapper {
voidinsertAttendance(Attendanceattendance);
voidinsertAttendance(Attendanceattendance);
/**
*获取实验班级信息
*@paramcourseId
*@paramstudentId
*@return
*/
@Select("select ecn.experimentalClassId from experimental_class_ning ecn left join experimental_class_student ecs on ecn.experimentalClassId=ecs.experimentalClassId where\n"+
"ecn.courseId=#{courseId} and ecs.studentId=#{studentId} GROUP BY ecn.experimentalClassId")
@Select("select staffName from staff where staffId =(select staffId from course where courseId=#{courseid})")
@Select("select name,userAvatars from experimental_class_ning ecs left join user u on ecs.userId=u.userId where ecs.experimentalClassId=#{experimentalClassId}")
@Select("select studentName from student where FIND_IN_SET(#{courseId},courseId) > 0 ")
@Select("select name,userAvatars from user u left join student s on (u.phone=s.phone and u.uniqueIdentificationAccount=s.uniqueIdentificationAccount) left join experimental_class_student ecs "+
List<Student>queryStudentName(IntegercourseId);
" on s.studentId=ecs.studentId where ecs.experimentalClassId=#{experimentalClassId} GROUP BY u.userId")
@ -107,4 +114,15 @@ public interface ExperimentallearningMapper {
*/
*/
@Select("select studentId from record where assesmentId=#{assesmentId}")
@Select("select studentId from record where assesmentId=#{assesmentId}")
List<Integer>queryStudentId(IntegerassesmentId);
List<Integer>queryStudentId(IntegerassesmentId);
@Select("select c.courseId,c.courseName from course c left join experimental_class_ning ecn on c.courseId=ecn.courseId left join experimental_class_student ecs "+
" on ecn.experimentalClassId=ecs.experimentalClassId where ecn.isdel=0 and c.isdel=0 and ecs.studentId=#{StudentId} GROUP BY c.courseId")
List<Course>queryStudentCourse(IntegerStudentId);
@Select("select DISTINCT hpm.projectId,projectName,isAttendance from hr_project_management hpm left join teacher_project tp on hpm.projectId=tp.projectId "+
" where tp.courseId=#{courseId} and tp.experimentalClassId=#{experimentalClassId} and tp.isOpenProject=0")
@Select("select DISTINCT hpm.projectId,projectName,isOpenProject,isAttendance from hr_project_management hpm left join teacher_project tp on hpm.projectId=tp.projectId "+
" where tp.courseId=#{courseId} and tp.experimentalClassId=#{experimentalClassId}")
@Update("update hr_project_management set isExperiment=#{isExperiment} where projectId=#{projectId}")
@Update("update teacher_project set isOpenProject=#{project.isOpenProject} where courseId=#{courseId} and experimentalClassId=#{experimentalClassId} and projectId=#{project.projectId}")
@Update("update hr_project_management set isAttendance=#{isAttendance} where projectId=#{projectId}")
@Update("update teacher_project set isAttendance=#{project.isAttendance} where courseId=#{courseId} and experimentalClassId=#{experimentalClassId} and projectId=#{project.projectId}")
@Select("select count(*) from hr_course_schedule where courseId=#{courseId}")
@Select("select count(*) from hr_course_schedule where courseId=#{courseId}")
IntegergetCourseSchedule(IntegercourseId);
IntegergetCourseSchedule(IntegercourseId);
@Select("select DISTINCT tc.projectId from hr_course_tc tc left join hr_project_management pm on tc.projectId=pm.projectId where tc.courseId=#{courseId} and pm.projectPermissions=0 ")
List<Integer>queryProject(IntegercourseId);
@Insert({"<script>",
"insert into teacher_project(courseId,experimentalClassId,projectId) values ",