|
|
@ -6,7 +6,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
|
|
|
|
|
|
<resultMap type="SurveyAnswer" id="SurveyAnswerResult">
|
|
|
|
<resultMap type="SurveyAnswer" id="SurveyAnswerResult">
|
|
|
|
<result property="answerId" column="answer_id" />
|
|
|
|
<result property="answerId" column="answer_id" />
|
|
|
|
<result property="paperId" column="paper_d" />
|
|
|
|
<result property="paperId" column="paper_id" />
|
|
|
|
<result property="questionId" column="question_id" />
|
|
|
|
<result property="questionId" column="question_id" />
|
|
|
|
<result property="optionId" column="option_id" />
|
|
|
|
<result property="optionId" column="option_id" />
|
|
|
|
<result property="userId" column="user_id" />
|
|
|
|
<result property="userId" column="user_id" />
|
|
|
@ -68,7 +68,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
insert into t_survey_answer
|
|
|
|
insert into t_survey_answer
|
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
<if test="answerId != null">answer_id,</if>
|
|
|
|
<if test="answerId != null">answer_id,</if>
|
|
|
|
<if test="paperId != null">paper_d,</if>
|
|
|
|
<if test="paperId != null">paper_id,</if>
|
|
|
|
<if test="questionId != null">question_id,</if>
|
|
|
|
<if test="questionId != null">question_id,</if>
|
|
|
|
<if test="optionId != null">option_id,</if>
|
|
|
|
<if test="optionId != null">option_id,</if>
|
|
|
|
<if test="userId != null">user_id,</if>
|
|
|
|
<if test="userId != null">user_id,</if>
|
|
|
@ -77,7 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
</trim>
|
|
|
|
</trim>
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
<if test="answerId != null">#{answerId},</if>
|
|
|
|
<if test="answerId != null">#{answerId},</if>
|
|
|
|
<if test="paperId != null">paper_d,</if>
|
|
|
|
<if test="paperId != null">#{paperId},</if>
|
|
|
|
<if test="questionId != null">#{questionId},</if>
|
|
|
|
<if test="questionId != null">#{questionId},</if>
|
|
|
|
<if test="optionId != null">#{optionId},</if>
|
|
|
|
<if test="optionId != null">#{optionId},</if>
|
|
|
|
<if test="userId != null">#{userId},</if>
|
|
|
|
<if test="userId != null">#{userId},</if>
|
|
|
@ -89,8 +89,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
<update id="updateSurveyAnswer" parameterType="SurveyAnswer">
|
|
|
|
<update id="updateSurveyAnswer" parameterType="SurveyAnswer">
|
|
|
|
update t_survey_answer
|
|
|
|
update t_survey_answer
|
|
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
|
|
<if test="questionId != null">paper_d = #{questionId},</if>
|
|
|
|
<if test="questionId != null">question_id = #{questionId},</if>
|
|
|
|
<if test="paperId != null">question_id = #{paperId},</if>
|
|
|
|
<if test="paperId != null">paper_id = #{paperId},</if>
|
|
|
|
<if test="optionId != null">option_id = #{optionId},</if>
|
|
|
|
<if test="optionId != null">option_id = #{optionId},</if>
|
|
|
|
<if test="userId != null">user_id = #{userId},</if>
|
|
|
|
<if test="userId != null">user_id = #{userId},</if>
|
|
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
|
|