| 123456789101112131415161718192021222324252627282930 |
- <?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.finikes.oc.vote.dao.ChoiceDao">
- <insert id="insert" useGeneratedKeys="true" keyProperty="id" keyColumn="id"
- parameterType="com.finikes.oc.vote.entity.Choice">
- INSERT INTO t_choice (option_id, passport_id, choose_time, proxy, assignee_id)
- VALUES (#{optionId}, #{passportId}, #{chooseTime}, #{proxy}, #{assigneeId})
- </insert>
- <update id="update" parameterType="com.finikes.oc.vote.entity.Choice">
- UPDATE t_choice SET option_id = #{optionId}, passport_id = #{passportId}, choose_time = #{chooseTime},
- proxy = #{proxy}, assignee_id = #{assigneeId}
- WHERE id = #{id}
- </update>
- <select id="selectByPrimaryKey" parameterType="integer" resultType="com.finikes.oc.vote.entity.Choice">
- SELECT id, option_id, passport_id, choose_time, proxy, assignee_id
- FROM t_choice
- WHERE id = #{primaryKey}
- </select>
- <delete id="deleteByPrimaryKey" parameterType="integer">
- DELETE
- FROM t_choice
- WHERE id = #{primaryKey}
- </delete>
- </mapper>
|