ExamArrangementStudentMapper.xml 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper
  3. PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
  4. "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  5. <mapper namespace="com.zhongzheng.modules.exam.mapper.ExamArrangementStudentMapper">
  6. <resultMap type="com.zhongzheng.modules.exam.domain.ExamArrangementStudent" id="ExamArrangementStudentResult">
  7. <result property="arrangementId" column="arrangement_id"/>
  8. <result property="studentId" column="student_id"/>
  9. </resultMap>
  10. <resultMap type="com.zhongzheng.modules.exam.vo.ExamUserVo" id="UserResult">
  11. <result property="userId" column="user_id"/>
  12. <result property="userAccout" column="user_accout"/>
  13. <result property="nickname" column="nickname"/>
  14. <result property="realname" column="realname"/>
  15. <result property="sex" column="sex"/>
  16. <result property="idCard" column="id_card"/>
  17. <result property="telphone" column="telphone"/>
  18. <result property="userLevel" column="user_level"/>
  19. <result property="userBirth" column="user_birth"/>
  20. <result property="eduLevel" column="edu_level"/>
  21. <result property="schoolId" column="school_id"/>
  22. <result property="major" column="major"/>
  23. <result property="entranceTime" column="entrance_time"/>
  24. <result property="openId" column="open_id"/>
  25. <result property="studentCertificateImg" column="student_certificate_img"/>
  26. <result property="idCardImg1" column="id_card_img1"/>
  27. <result property="idCardImg2" column="id_card_img2"/>
  28. <result property="country" column="country"/>
  29. <result property="province" column="province"/>
  30. <result property="city" column="city"/>
  31. <result property="integral" column="integral"/>
  32. <association property="examArrangementVo" javaType="com.zhongzheng.modules.exam.vo.ExamArrangementVo" resultMap="ExamArrangementResult"/>
  33. </resultMap>
  34. <resultMap type="com.zhongzheng.modules.exam.vo.ExamArrangementVo" id="ExamArrangementResult">
  35. <result property="id" column="id"/>
  36. <result property="examTypeId" column="uexam_type_id"/>
  37. <result property="examType" column="exam_type"/>
  38. <result property="signStartTime" column="sign_start_time"/>
  39. <result property="signEndTime" column="sign_end_time"/>
  40. <result property="examAdress" column="exam_adress"/>
  41. <result property="examUrl" column="exam_url"/>
  42. <result property="remarks" column="remarks"/>
  43. <result property="releaseNum" column="release_num"/>
  44. <result property="subscrPe" column="subscr_pe"/>
  45. <result property="signUpPe" column="sign_up_pe"/>
  46. <result property="releaseTime" column="release_time"/>
  47. <result property="updateTime" column="update_time"/>
  48. <result property="createTime" column="create_time"/>
  49. <result property="examTime" column="exam_time"/>
  50. <result property="regGuide" column="reg_guide"/>
  51. <result property="examPeriod" column="exam_period"/>
  52. <result property="status" column="status"/>
  53. <result property="examForm" column="exam_form"/>
  54. <result property="examFromUrl" column="exam_from_url"/>
  55. <result property="printUrl" column="print_url"/>
  56. <result property="gradesUrl" column="grades_url"/>
  57. <result property="scoreLineUrl" column="score_line_url"/>
  58. <result property="certificate" column="certificate"/>
  59. </resultMap>
  60. <select id="selectExamUserList" parameterType="com.zhongzheng.modules.exam.bo.ExamArrangementQueryBo" resultMap="UserResult">
  61. SELECT
  62. u.*,
  63. e.*
  64. FROM
  65. exam_arrangement_student s
  66. LEFT JOIN `user` u ON s.student_id = u.user_id
  67. LEFT JOIN exam_arrangement e ON s.arrangement_id = e.id
  68. LEFT JOIN exam_arrangement_time t ON t.arrangement_id = e.id
  69. WHERE 1=1
  70. <if test="startTime != null and startTime != ''">
  71. AND t.start_time BETWEEN #{startTime} and #{endTime}
  72. </if>
  73. </select>
  74. </mapper>