File was renamed from src/main/resources/mapper/ExamPaperQuestionCustomerAnswerMapper.xml |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ycl.jxkg.mapper.ExamPaperQuestionCustomerAnswerMapper"> |
| | | <resultMap id="BaseResultMap" type="com.ycl.jxkg.domain.entity.ExamPaperQuestionCustomerAnswer"> |
| | | <mapper namespace="com.ycl.jxkg.mapper.ExamPaperScoreDetailMapper"> |
| | | <resultMap id="BaseResultMap" type="com.ycl.jxkg.domain.entity.ExamPaperScoreDetail"> |
| | | <id column="id" jdbcType="INTEGER" property="id"/> |
| | | <result column="question_id" jdbcType="INTEGER" property="questionId"/> |
| | | <result column="exam_paper_id" jdbcType="INTEGER" property="examPaperId"/> |
| | |
| | | |
| | | |
| | | <select id="selectCountByDate" resultType="com.ycl.jxkg.domain.other.KeyValue"> |
| | | SELECT create_time as name, COUNT(create_time) as value |
| | | SELECT answer_time as name, sum(question_count) as value |
| | | from |
| | | ( |
| | | SELECT DATE_FORMAT(create_time, '%Y-%m-%d') as create_time from t_exam_paper_question_customer_answer |
| | | WHERE create_time between #{startTime} and #{endTime} |
| | | SELECT question_count ,DATE_FORMAT(answer_time, '%Y-%m-%d') as answer_time from t_exam_paper_score |
| | | WHERE answer_time between #{startTime} and #{endTime} |
| | | ) a |
| | | GROUP BY create_time |
| | | GROUP BY answer_time |
| | | </select> |
| | | |
| | | <update id="updateScore" parameterType="java.util.List"> |