|
@@ -7,34 +7,29 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<resultMap type="LiveLotteryConf" id="LiveLotteryConfResult">
|
|
<resultMap type="LiveLotteryConf" id="LiveLotteryConfResult">
|
|
<result property="lotteryId" column="lottery_id" />
|
|
<result property="lotteryId" column="lottery_id" />
|
|
<result property="liveId" column="live_id" />
|
|
<result property="liveId" column="live_id" />
|
|
- <result property="productId" column="product_id" />
|
|
|
|
- <result property="prizeLevel" column="prize_level" />
|
|
|
|
- <result property="perLotteryNum" column="per_lottery_num" />
|
|
|
|
- <result property="totalLots" column="total_lots" />
|
|
|
|
- <result property="totalSend" column="total_send" />
|
|
|
|
<result property="require" column="require" />
|
|
<result property="require" column="require" />
|
|
<result property="requireConf" column="require_conf" />
|
|
<result property="requireConf" column="require_conf" />
|
|
<result property="duration" column="duration" />
|
|
<result property="duration" column="duration" />
|
|
<result property="desc" column="desc" />
|
|
<result property="desc" column="desc" />
|
|
<result property="createTime" column="create_time" />
|
|
<result property="createTime" column="create_time" />
|
|
- <result property="udpateTime" column="update_time" />
|
|
|
|
|
|
+ <result property="updateTime" column="update_time" />
|
|
<result property="createBy" column="create_by" />
|
|
<result property="createBy" column="create_by" />
|
|
<result property="updateBy" column="update_by" />
|
|
<result property="updateBy" column="update_by" />
|
|
|
|
+ <result property="lotteryStatus" column="lottery_status" />
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectLiveLotteryConfVo">
|
|
<sql id="selectLiveLotteryConfVo">
|
|
- select lottery_id, live_id, product_id, prize_level, per_lottery_num, total_lots, total_send, `require`, require_conf, duration, `desc`, create_time, update_time, create_by, update_by from live_lottery_conf
|
|
|
|
|
|
+ select lottery_id, live_id, `require`, require_conf, duration, `desc`, create_time, update_time, create_by, update_by, lottery_status from live_lottery_conf
|
|
</sql>
|
|
</sql>
|
|
|
|
|
|
<select id="selectLiveLotteryConfList" parameterType="LiveLotteryConf" resultMap="LiveLotteryConfResult">
|
|
<select id="selectLiveLotteryConfList" parameterType="LiveLotteryConf" resultMap="LiveLotteryConfResult">
|
|
<include refid="selectLiveLotteryConfVo"/>
|
|
<include refid="selectLiveLotteryConfVo"/>
|
|
<where>
|
|
<where>
|
|
<if test="liveId != null "> and live_id = #{liveId}</if>
|
|
<if test="liveId != null "> and live_id = #{liveId}</if>
|
|
- <if test="productId != null "> and product_id = #{productId}</if>
|
|
|
|
- <if test="prizeLevel != null "> and prize_level = #{prizeLevel}</if>
|
|
|
|
<if test="require != null "> and `require` = #{require}</if>
|
|
<if test="require != null "> and `require` = #{require}</if>
|
|
<if test="desc != null and desc != ''"> and `desc` = #{desc}</if>
|
|
<if test="desc != null and desc != ''"> and `desc` = #{desc}</if>
|
|
<if test="createTime != null "> and create_time = #{createTime}</if>
|
|
<if test="createTime != null "> and create_time = #{createTime}</if>
|
|
|
|
+ <if test="lotteryStatus != null "> and lottery_status = #{lotteryStatus}</if>
|
|
</where>
|
|
</where>
|
|
</select>
|
|
</select>
|
|
|
|
|
|
@@ -47,35 +42,27 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
insert into live_lottery_conf
|
|
insert into live_lottery_conf
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="liveId != null">live_id,</if>
|
|
<if test="liveId != null">live_id,</if>
|
|
- <if test="productId != null">product_id,</if>
|
|
|
|
- <if test="prizeLevel != null">prize_level,</if>
|
|
|
|
- <if test="perLotteryNum != null">per_lottery_num,</if>
|
|
|
|
- <if test="totalLots != null">total_lots,</if>
|
|
|
|
- <if test="totalSend != null">total_send,</if>
|
|
|
|
<if test="require != null">`require`,</if>
|
|
<if test="require != null">`require`,</if>
|
|
<if test="requireConf != null">require_conf,</if>
|
|
<if test="requireConf != null">require_conf,</if>
|
|
<if test="duration != null">duration,</if>
|
|
<if test="duration != null">duration,</if>
|
|
<if test="desc != null and desc != ''">`desc`,</if>
|
|
<if test="desc != null and desc != ''">`desc`,</if>
|
|
<if test="createTime != null">create_time,</if>
|
|
<if test="createTime != null">create_time,</if>
|
|
- <if test="udpateTime != null">update_time,</if>
|
|
|
|
|
|
+ <if test="updateTime != null">update_time,</if>
|
|
<if test="createBy != null">create_by,</if>
|
|
<if test="createBy != null">create_by,</if>
|
|
<if test="updateBy != null">update_by,</if>
|
|
<if test="updateBy != null">update_by,</if>
|
|
|
|
+ <if test="lotteryStatus != null">lottery_status,</if>
|
|
</trim>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="liveId != null">#{liveId},</if>
|
|
<if test="liveId != null">#{liveId},</if>
|
|
- <if test="productId != null">#{productId},</if>
|
|
|
|
- <if test="prizeLevel != null">#{prizeLevel},</if>
|
|
|
|
- <if test="perLotteryNum != null">#{perLotteryNum},</if>
|
|
|
|
- <if test="totalLots != null">#{totalLots},</if>
|
|
|
|
- <if test="totalSend != null">#{totalSend},</if>
|
|
|
|
<if test="require != null">#{require},</if>
|
|
<if test="require != null">#{require},</if>
|
|
<if test="requireConf != null">#{requireConf},</if>
|
|
<if test="requireConf != null">#{requireConf},</if>
|
|
<if test="duration != null">#{duration},</if>
|
|
<if test="duration != null">#{duration},</if>
|
|
<if test="desc != null and desc != ''">#{desc},</if>
|
|
<if test="desc != null and desc != ''">#{desc},</if>
|
|
<if test="createTime != null">#{createTime},</if>
|
|
<if test="createTime != null">#{createTime},</if>
|
|
- <if test="udpateTime != null">#{udpateTime},</if>
|
|
|
|
|
|
+ <if test="updateTime != null">#{updateTime},</if>
|
|
<if test="createBy != null">#{createBy},</if>
|
|
<if test="createBy != null">#{createBy},</if>
|
|
<if test="updateBy != null">#{updateBy},</if>
|
|
<if test="updateBy != null">#{updateBy},</if>
|
|
|
|
+ <if test="lotteryStatus != null">#{lotteryStatus},</if>
|
|
</trim>
|
|
</trim>
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
@@ -83,19 +70,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
update live_lottery_conf
|
|
update live_lottery_conf
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<if test="liveId != null">live_id = #{liveId},</if>
|
|
<if test="liveId != null">live_id = #{liveId},</if>
|
|
- <if test="productId != null">product_id = #{productId},</if>
|
|
|
|
- <if test="prizeLevel != null">prize_level = #{prizeLevel},</if>
|
|
|
|
- <if test="perLotteryNum != null">per_lottery_num = #{perLotteryNum},</if>
|
|
|
|
- <if test="totalLots != null">total_lots = #{totalLots},</if>
|
|
|
|
- <if test="totalSend != null">total_send = #{totalSend},</if>
|
|
|
|
<if test="require != null">`require` = #{require},</if>
|
|
<if test="require != null">`require` = #{require},</if>
|
|
<if test="requireConf != null">require_conf = #{requireConf},</if>
|
|
<if test="requireConf != null">require_conf = #{requireConf},</if>
|
|
<if test="duration != null">duration = #{duration},</if>
|
|
<if test="duration != null">duration = #{duration},</if>
|
|
<if test="desc != null and desc != ''">`desc` = #{desc},</if>
|
|
<if test="desc != null and desc != ''">`desc` = #{desc},</if>
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
- <if test="udpateTime != null">update_time = #{udpateTime},</if>
|
|
|
|
|
|
+ <if test="updateTime != null">update_time = #{updateTime},</if>
|
|
<if test="createBy != null">create_by = #{createBy},</if>
|
|
<if test="createBy != null">create_by = #{createBy},</if>
|
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
|
|
|
+ <if test="lotteryStatus != null">lottery_status = #{lotteryStatus},</if>
|
|
</trim>
|
|
</trim>
|
|
where lottery_id = #{lotteryId}
|
|
where lottery_id = #{lotteryId}
|
|
</update>
|
|
</update>
|