| | |
| | | <result column="ir_state" property="state" jdbcType="INTEGER" /> |
| | | <result column="ir_create_time" property="createTime" jdbcType="TIMESTAMP" /> |
| | | <result column="ir_update_time" property="updateTime" jdbcType="TIMESTAMP" /> |
| | | <result column="ir_end_time" property="endTime" jdbcType="TIMESTAMP"/>
|
| | | |
| | | <result column="taskName" property="taskName" jdbcType="VARCHAR" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List">ir_id,ir_cid,ir_task_id,ir_uid,ir_gold_coin,ir_state,ir_create_time,ir_update_time |
| | | </sql> |
| | | <select id="selectByPrimaryKey" resultMap="BaseResultMap" |
| | | parameterType="java.lang.Long"> |
| | | select |
| | | <include refid="Base_Column_List" /> |
| | | from yeshi_ec_integral_task_record where ir_id = #{id,jdbcType=BIGINT} |
| | | </select> |
| | | <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">delete from |
| | | yeshi_ec_integral_task_record where ir_id = #{id,jdbcType=BIGINT} |
| | | </delete> |
| | | <insert id="insert" parameterType="com.yeshi.fanli.entity.integral.IntegralTaskRecord" |
| | | useGeneratedKeys="true" keyProperty="id">insert into |
| | | yeshi_ec_integral_task_record |
| | | (ir_id,ir_cid,ir_task_id,ir_uid,ir_gold_coin,ir_state,ir_create_time,ir_update_time) |
| | | values |
| | | (#{id,jdbcType=BIGINT},#{cid,jdbcType=BIGINT},#{taskId,jdbcType=BIGINT},#{uid,jdbcType=BIGINT},#{goldCoin,jdbcType=INTEGER},#{state,jdbcType=INTEGER},#{createTime,jdbcType=TIMESTAMP},#{updateTime,jdbcType=TIMESTAMP}) |
| | | </insert> |
| | | <insert id="insertSelective" parameterType="com.yeshi.fanli.entity.integral.IntegralTaskRecord" |
| | | useGeneratedKeys="true" keyProperty="id"> |
| | | insert into yeshi_ec_integral_task_record |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">ir_id,</if> |
| | | <if test="cid != null">ir_cid,</if> |
| | | <if test="taskId != null">ir_task_id,</if> |
| | | <if test="uid != null">ir_uid,</if> |
| | | <if test="goldCoin != null">ir_gold_coin,</if> |
| | | <if test="state != null">ir_state,</if> |
| | | <if test="createTime != null">ir_create_time,</if> |
| | | <if test="updateTime != null">ir_update_time,</if> |
| | | </trim> |
| | | values |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">#{id,jdbcType=BIGINT},</if> |
| | | <if test="cid != null">#{cid,jdbcType=BIGINT},</if> |
| | | <if test="taskId != null">#{taskId,jdbcType=BIGINT},</if> |
| | | <if test="uid != null">#{uid,jdbcType=BIGINT},</if> |
| | | <if test="goldCoin != null">#{goldCoin,jdbcType=INTEGER},</if> |
| | | <if test="state != null">#{state,jdbcType=INTEGER},</if> |
| | | <if test="createTime != null">#{createTime,jdbcType=TIMESTAMP},</if> |
| | | <if test="updateTime != null">#{updateTime,jdbcType=TIMESTAMP},</if> |
| | | </trim> |
| | | </insert> |
| | | <update id="updateByPrimaryKey" parameterType="com.yeshi.fanli.entity.integral.IntegralTaskRecord">update |
| | | yeshi_ec_integral_task_record set ir_cid = |
| | | #{cid,jdbcType=BIGINT},ir_task_id = #{taskId,jdbcType=BIGINT},ir_uid = |
| | | #{uid,jdbcType=BIGINT},ir_gold_coin = |
| | | #{goldCoin,jdbcType=INTEGER},ir_state = |
| | | #{state,jdbcType=INTEGER},ir_create_time = |
| | | #{createTime,jdbcType=TIMESTAMP},ir_update_time = |
| | | #{updateTime,jdbcType=TIMESTAMP} where ir_id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | <update id="updateByPrimaryKeySelective" parameterType="com.yeshi.fanli.entity.integral.IntegralTaskRecord"> |
| | | update yeshi_ec_integral_task_record |
| | | <set> |
| | | <if test="cid != null">ir_cid=#{cid,jdbcType=BIGINT},</if> |
| | | <if test="taskId != null">ir_task_id=#{taskId,jdbcType=BIGINT},</if> |
| | | <if test="uid != null">ir_uid=#{uid,jdbcType=BIGINT},</if> |
| | | <if test="goldCoin != null">ir_gold_coin=#{goldCoin,jdbcType=INTEGER},</if> |
| | | <if test="state != null">ir_state=#{state,jdbcType=INTEGER},</if> |
| | | <if test="createTime != null">ir_create_time=#{createTime,jdbcType=TIMESTAMP},</if> |
| | | <if test="updateTime != null">ir_update_time=#{updateTime,jdbcType=TIMESTAMP},</if> |
| | | </set> |
| | | where ir_id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | <sql id="Base_Column_List">ir_id,ir_cid,ir_task_id,ir_uid,ir_gold_coin,ir_state,ir_create_time,ir_update_time,ir_end_time</sql>
|
| | | <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Long">select
|
| | | <include refid="Base_Column_List"/>from yeshi_ec_integral_task_record where ir_id = #{id,jdbcType=BIGINT}
|
| | | </select>
|
| | | <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">delete from yeshi_ec_integral_task_record where ir_id = #{id,jdbcType=BIGINT}</delete>
|
| | | <insert id="insert" parameterType="com.yeshi.fanli.entity.integral.IntegralTaskRecord" useGeneratedKeys="true" keyProperty="id">insert into yeshi_ec_integral_task_record (ir_id,ir_cid,ir_task_id,ir_uid,ir_gold_coin,ir_state,ir_create_time,ir_update_time,ir_end_time) values (#{id,jdbcType=BIGINT},#{cid,jdbcType=BIGINT},#{taskId,jdbcType=BIGINT},#{uid,jdbcType=BIGINT},#{goldCoin,jdbcType=INTEGER},#{state,jdbcType=INTEGER},#{createTime,jdbcType=TIMESTAMP},#{updateTime,jdbcType=TIMESTAMP},#{endTime,jdbcType=TIMESTAMP})</insert>
|
| | | <insert id="insertSelective" parameterType="com.yeshi.fanli.entity.integral.IntegralTaskRecord" useGeneratedKeys="true" keyProperty="id">insert into yeshi_ec_integral_task_record
|
| | | <trim prefix="(" suffix=")" suffixOverrides=",">
|
| | | <if test="id != null">ir_id,</if>
|
| | | <if test="cid != null">ir_cid,</if>
|
| | | <if test="taskId != null">ir_task_id,</if>
|
| | | <if test="uid != null">ir_uid,</if>
|
| | | <if test="goldCoin != null">ir_gold_coin,</if>
|
| | | <if test="state != null">ir_state,</if>
|
| | | <if test="createTime != null">ir_create_time,</if>
|
| | | <if test="updateTime != null">ir_update_time,</if>
|
| | | <if test="endTime != null">ir_end_time,</if>
|
| | | </trim>values
|
| | | <trim prefix="(" suffix=")" suffixOverrides=",">
|
| | | <if test="id != null">#{id,jdbcType=BIGINT},</if>
|
| | | <if test="cid != null">#{cid,jdbcType=BIGINT},</if>
|
| | | <if test="taskId != null">#{taskId,jdbcType=BIGINT},</if>
|
| | | <if test="uid != null">#{uid,jdbcType=BIGINT},</if>
|
| | | <if test="goldCoin != null">#{goldCoin,jdbcType=INTEGER},</if>
|
| | | <if test="state != null">#{state,jdbcType=INTEGER},</if>
|
| | | <if test="createTime != null">#{createTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="updateTime != null">#{updateTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="endTime != null">#{endTime,jdbcType=TIMESTAMP},</if>
|
| | | </trim>
|
| | | </insert>
|
| | | <update id="updateByPrimaryKey" parameterType="com.yeshi.fanli.entity.integral.IntegralTaskRecord">update yeshi_ec_integral_task_record set ir_cid = #{cid,jdbcType=BIGINT},ir_task_id = #{taskId,jdbcType=BIGINT},ir_uid = #{uid,jdbcType=BIGINT},ir_gold_coin = #{goldCoin,jdbcType=INTEGER},ir_state = #{state,jdbcType=INTEGER},ir_create_time = #{createTime,jdbcType=TIMESTAMP},ir_update_time = #{updateTime,jdbcType=TIMESTAMP},ir_end_time = #{endTime,jdbcType=TIMESTAMP} where ir_id = #{id,jdbcType=BIGINT}</update>
|
| | | <update id="updateByPrimaryKeySelective" parameterType="com.yeshi.fanli.entity.integral.IntegralTaskRecord">update yeshi_ec_integral_task_record
|
| | | <set>
|
| | | <if test="cid != null">ir_cid=#{cid,jdbcType=BIGINT},</if>
|
| | | <if test="taskId != null">ir_task_id=#{taskId,jdbcType=BIGINT},</if>
|
| | | <if test="uid != null">ir_uid=#{uid,jdbcType=BIGINT},</if>
|
| | | <if test="goldCoin != null">ir_gold_coin=#{goldCoin,jdbcType=INTEGER},</if>
|
| | | <if test="state != null">ir_state=#{state,jdbcType=INTEGER},</if>
|
| | | <if test="createTime != null">ir_create_time=#{createTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="updateTime != null">ir_update_time=#{updateTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="endTime != null">ir_end_time=#{endTime,jdbcType=TIMESTAMP},</if>
|
| | | </set> where ir_id = #{id,jdbcType=BIGINT}
|
| | | </update> |
| | | |
| | | |
| | | <update id="updateReceived" parameterType="Long"> |
| | |
| | | yeshi_ec_integral_task_record SET ir_state = 1,ir_update_time = NOW() |
| | | WHERE ir_state = 0 AND ir_uid = #{uid} |
| | | </update> |
| | | |
| | | <update id="invalidGoldCoin">
|
| | | UPDATE yeshi_ec_integral_task_record SET ir_state = 2 |
| | | WHERE ir_end_time <![CDATA[<]]> NOW() AND ir_state = 0
|
| | | </update> |
| | | |
| | | <select id="listNotReceived" resultMap="BaseResultMap"> |
| | | SELECT tc.`tc_name` AS |