<?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.yeshi.fanli.dao.mybatis.taobao.TaoBaoGoodsBriefMapper">
|
<resultMap id="BaseResultMap"
|
type="com.yeshi.fanli.entity.taobao.TaoBaoGoodsBrief">
|
<id column="id" property="id" jdbcType="BIGINT" />
|
<result column="rootCatId" property="rootCatId" jdbcType="INTEGER" />
|
<result column="eventCreatorId" property="eventCreatorId"
|
jdbcType="INTEGER" />
|
<result column="leafCatId" property="leafCatId" jdbcType="INTEGER" />
|
<result column="debugInfo" property="debugInfo" jdbcType="VARCHAR" />
|
<result column="rootCatScore" property="rootCatScore" jdbcType="INTEGER" />
|
<result column="sellerId" property="sellerId" jdbcType="BIGINT" />
|
<result column="userType" property="userType" jdbcType="INTEGER" />
|
<result column="shopTitle" property="shopTitle" jdbcType="VARCHAR" />
|
<result column="pictUrl" property="pictUrl" jdbcType="VARCHAR" />
|
<result column="title" property="title" jdbcType="VARCHAR" />
|
<result column="auctionId" property="auctionId" jdbcType="BIGINT" />
|
<result column="couponLink" property="couponLink" jdbcType="VARCHAR" />
|
<result column="couponLinkTaoToken" property="couponLinkTaoToken"
|
jdbcType="VARCHAR" />
|
<result column="couponActivityId" property="couponActivityId"
|
jdbcType="VARCHAR" />
|
<result column="biz30day" property="biz30day" jdbcType="INTEGER" />
|
<result column="tkRate" property="tkRate" jdbcType="DECIMAL" />
|
<result column="nick" property="nick" jdbcType="VARCHAR" />
|
<result column="includeDxjh" property="includeDxjh" jdbcType="INTEGER" />
|
<result column="reservePrice" property="reservePrice" jdbcType="DECIMAL" />
|
<result column="tkCommFee" property="tkCommFee" jdbcType="DECIMAL" />
|
<result column="totalFee" property="totalFee" jdbcType="DECIMAL" />
|
<result column="totalNum" property="totalNum" jdbcType="INTEGER" />
|
<result column="zkPrice" property="zkPrice" jdbcType="DECIMAL" />
|
<result column="dayLeft" property="dayLeft" jdbcType="INTEGER" />
|
<result column="tk3rdRate" property="tk3rdRate" jdbcType="VARCHAR" />
|
<result column="auctionUrl" property="auctionUrl" jdbcType="VARCHAR" />
|
<result column="hasRecommended" property="hasRecommended"
|
jdbcType="INTEGER" />
|
<result column="hasSame" property="hasSame" jdbcType="INTEGER" />
|
<result column="sameItemPid" property="sameItemPid" jdbcType="BIGINT" />
|
<result column="couponTotalCount" property="couponTotalCount"
|
jdbcType="INTEGER" />
|
<result column="couponLeftCount" property="couponLeftCount"
|
jdbcType="INTEGER" />
|
<result column="couponAmount" property="couponAmount" jdbcType="DECIMAL" />
|
<result column="eventRate" property="eventRate" jdbcType="VARCHAR" />
|
<result column="couponShortLink" property="couponShortLink"
|
jdbcType="VARCHAR" />
|
<result column="couponInfo" property="couponInfo" jdbcType="VARCHAR" />
|
<result column="couponStartFee" property="couponStartFee"
|
jdbcType="DECIMAL" />
|
<result column="couponEffectiveStartTime" property="couponEffectiveStartTime"
|
jdbcType="VARCHAR" />
|
<result column="couponEffectiveEndTime" property="couponEffectiveEndTime"
|
jdbcType="VARCHAR" />
|
<result column="hasUmpBonus" property="hasUmpBonus" jdbcType="VARCHAR" />
|
<result column="isBizActivity" property="isBizActivity"
|
jdbcType="VARCHAR" />
|
<result column="umpBonus" property="umpBonus" jdbcType="VARCHAR" />
|
<result column="rootCategoryName" property="rootCategoryName"
|
jdbcType="VARCHAR" />
|
<result column="couponOriLink" property="couponOriLink"
|
jdbcType="VARCHAR" />
|
<result column="userTypeName" property="userTypeName" jdbcType="VARCHAR" />
|
<result column="createtime" property="createtime" jdbcType="TIMESTAMP" />
|
<result column="tkMktStatus" property="tkMktStatus" jdbcType="VARCHAR" />
|
<result column="rlRate" property="rlRate" jdbcType="DECIMAL" />
|
<result column="updatetime" property="updatetime" jdbcType="TIMESTAMP" />
|
<result column="state" property="state" jdbcType="INTEGER" />
|
<result column="totalSales" property="totalSales" jdbcType="INTEGER" />
|
</resultMap>
|
<sql id="Base_Column_List">id,rootCatId,eventCreatorId,leafCatId,debugInfo,rootCatScore,sellerId,userType,shopTitle,pictUrl,title,auctionId,couponLink,couponLinkTaoToken,couponActivityId,biz30day,tkRate,nick,includeDxjh,reservePrice,tkCommFee,totalFee,totalNum,zkPrice,dayLeft,tk3rdRate,auctionUrl,rlRate,hasRecommended,hasSame,sameItemPid,couponTotalCount,couponLeftCount,couponAmount,eventRate,couponShortLink,couponInfo,couponStartFee,couponEffectiveStartTime,couponEffectiveEndTime,hasUmpBonus,isBizActivity,umpBonus,rootCategoryName,couponOriLink,userTypeName,createtime,tkMktStatus,updatetime,state,totalSales
|
</sql>
|
<select id="selectByPrimaryKey" resultMap="BaseResultMap"
|
parameterType="java.lang.Long">
|
select
|
<include refid="Base_Column_List" />
|
from yeshi_ec_taobao_goods where id = #{id,jdbcType=BIGINT}
|
</select>
|
|
<select id="queryGoodsByMaxCreateTime" resultMap="BaseResultMap">
|
select
|
<include refid="Base_Column_List" />
|
from yeshi_ec_taobao_goods where createtime <![CDATA[<
|
]]>
|
#{maxTime} order by createtime limit #{start},#{count}
|
</select>
|
|
|
<select id="queryCanDeleteGoods" resultType="java.lang.Long">
|
SELECT g.`auctionId` FROM yeshi_ec_taobao_goods g LEFT JOIN
|
`yeshi_ec_recommend_section_goods` sg ON sg.`goodsid`=g.`id` WHERE
|
sg.`id` IS NULL AND g.createtime <![CDATA[<
|
]]>
|
#{maxTime} order by g.createtime limit #{start},#{count}
|
</select>
|
|
|
<select id="queryCanDeleteGoodsCount" resultType="java.lang.Long">
|
SELECT count(g.id) FROM yeshi_ec_taobao_goods g LEFT JOIN
|
`yeshi_ec_recommend_section_goods` sg ON sg.`goodsid`=g.`id` WHERE
|
sg.`id` IS NULL AND createtime <![CDATA[<
|
]]>
|
#{maxTime}
|
</select>
|
|
|
<select id="queryGoodsByMaxUpdateTime" resultMap="BaseResultMap">
|
select
|
<include refid="Base_Column_List" />
|
from yeshi_ec_taobao_goods where updatetime is null or updatetime <![CDATA[<
|
]]>
|
#{maxTime} order by updatetime limit #{start},#{count}
|
</select>
|
|
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">delete from
|
yeshi_ec_taobao_goods where id = #{id,jdbcType=BIGINT}
|
</delete>
|
|
<delete id="deleteByAuctionId" parameterType="java.lang.Long">delete from
|
yeshi_ec_taobao_goods where auctionId = #{auctionId,jdbcType=BIGINT}
|
</delete>
|
|
|
<insert id="insert" parameterType="com.yeshi.fanli.entity.taobao.TaoBaoGoodsBrief"
|
useGeneratedKeys="true" keyProperty="id">insert into yeshi_ec_taobao_goods
|
(id,rootCatId,eventCreatorId,leafCatId,debugInfo,rootCatScore,sellerId,userType,shopTitle,pictUrl,title,auctionId,couponLink,couponLinkTaoToken,couponActivityId,biz30day,tkRate,nick,includeDxjh,reservePrice,tkCommFee,totalFee,totalNum,zkPrice,dayLeft,tk3rdRate,auctionUrl,rlRate,hasRecommended,hasSame,sameItemPid,couponTotalCount,couponLeftCount,couponAmount,eventRate,couponShortLink,couponInfo,couponStartFee,couponEffectiveStartTime,couponEffectiveEndTime,hasUmpBonus,isBizActivity,umpBonus,rootCategoryName,couponOriLink,userTypeName,createtime,tkMktStatus,updatetime,state,totalSales)
|
values
|
(#{id,jdbcType=BIGINT},#{rootCatId,jdbcType=INTEGER},#{eventCreatorId,jdbcType=INTEGER},#{leafCatId,jdbcType=INTEGER},#{debugInfo,jdbcType=VARCHAR},#{rootCatScore,jdbcType=INTEGER},#{sellerId,jdbcType=BIGINT},#{userType,jdbcType=INTEGER},#{shopTitle,jdbcType=VARCHAR},#{pictUrl,jdbcType=VARCHAR},#{title,jdbcType=VARCHAR},#{auctionId,jdbcType=BIGINT},#{couponLink,jdbcType=VARCHAR},#{couponLinkTaoToken,jdbcType=VARCHAR},#{couponActivityId,jdbcType=VARCHAR},#{biz30day,jdbcType=INTEGER},#{tkRate,jdbcType=DECIMAL},#{nick,jdbcType=VARCHAR},#{includeDxjh,jdbcType=INTEGER},#{reservePrice,jdbcType=DECIMAL},#{tkCommFee,jdbcType=DECIMAL},#{totalFee,jdbcType=DECIMAL},#{totalNum,jdbcType=INTEGER},#{zkPrice,jdbcType=DECIMAL},#{dayLeft,jdbcType=INTEGER},#{tk3rdRate,jdbcType=VARCHAR},#{auctionUrl,jdbcType=VARCHAR},#{rlRate,jdbcType=DECIMAL},#{hasRecommended,jdbcType=INTEGER},#{hasSame,jdbcType=INTEGER},#{sameItemPid,jdbcType=BIGINT},#{couponTotalCount,jdbcType=INTEGER},#{couponLeftCount,jdbcType=INTEGER},#{couponAmount,jdbcType=DECIMAL},#{eventRate,jdbcType=VARCHAR},#{couponShortLink,jdbcType=VARCHAR},#{couponInfo,jdbcType=VARCHAR},#{couponStartFee,jdbcType=DECIMAL},#{couponEffectiveStartTime,jdbcType=VARCHAR},#{couponEffectiveEndTime,jdbcType=VARCHAR},#{hasUmpBonus,jdbcType=VARCHAR},#{isBizActivity,jdbcType=VARCHAR},#{umpBonus,jdbcType=VARCHAR},#{rootCategoryName,jdbcType=VARCHAR},#{couponOriLink,jdbcType=VARCHAR},#{userTypeName,jdbcType=VARCHAR},#{createtime,jdbcType=TIMESTAMP},#{tkMktStatus,jdbcType=VARCHAR},#{updatetime,jdbcType=TIMESTAMP},#{state,jdbcType=INTEGER},#{totalSales,jdbcType=INTEGER})
|
</insert>
|
<insert id="insertSelective" parameterType="com.yeshi.fanli.entity.taobao.TaoBaoGoodsBrief"
|
useGeneratedKeys="true" keyProperty="id">
|
insert into yeshi_ec_taobao_goods
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
<if test="id != null">id,</if>
|
<if test="rootCatId != null">rootCatId,</if>
|
<if test="eventCreatorId != null">eventCreatorId,</if>
|
<if test="leafCatId != null">leafCatId,</if>
|
<if test="debugInfo != null">debugInfo,</if>
|
<if test="rootCatScore != null">rootCatScore,</if>
|
<if test="sellerId != null">sellerId,</if>
|
<if test="userType != null">userType,</if>
|
<if test="shopTitle != null">shopTitle,</if>
|
<if test="pictUrl != null">pictUrl,</if>
|
<if test="title != null">title,</if>
|
<if test="auctionId != null">auctionId,</if>
|
<if test="couponLink != null">couponLink,</if>
|
<if test="couponLinkTaoToken != null">couponLinkTaoToken,</if>
|
<if test="couponActivityId != null">couponActivityId,</if>
|
<if test="biz30day != null">biz30day,</if>
|
<if test="tkRate != null">tkRate,</if>
|
<if test="nick != null">nick,</if>
|
<if test="includeDxjh != null">includeDxjh,</if>
|
<if test="reservePrice != null">reservePrice,</if>
|
<if test="tkCommFee != null">tkCommFee,</if>
|
<if test="totalFee != null">totalFee,</if>
|
<if test="totalNum != null">totalNum,</if>
|
<if test="zkPrice != null">zkPrice,</if>
|
<if test="dayLeft != null">dayLeft,</if>
|
<if test="tk3rdRate != null">tk3rdRate,</if>
|
<if test="auctionUrl != null">auctionUrl,</if>
|
<if test="rlRate != null">rlRate,</if>
|
<if test="hasRecommended != null">hasRecommended,</if>
|
<if test="hasSame != null">hasSame,</if>
|
<if test="sameItemPid != null">sameItemPid,</if>
|
<if test="couponTotalCount != null">couponTotalCount,</if>
|
<if test="couponLeftCount != null">couponLeftCount,</if>
|
<if test="couponAmount != null">couponAmount,</if>
|
<if test="eventRate != null">eventRate,</if>
|
<if test="couponShortLink != null">couponShortLink,</if>
|
<if test="couponInfo != null">couponInfo,</if>
|
<if test="couponStartFee != null">couponStartFee,</if>
|
<if test="couponEffectiveStartTime != null">couponEffectiveStartTime,</if>
|
<if test="couponEffectiveEndTime != null">couponEffectiveEndTime,</if>
|
<if test="hasUmpBonus != null">hasUmpBonus,</if>
|
<if test="isBizActivity != null">isBizActivity,</if>
|
<if test="umpBonus != null">umpBonus,</if>
|
<if test="rootCategoryName != null">rootCategoryName,</if>
|
<if test="couponOriLink != null">couponOriLink,</if>
|
<if test="userTypeName != null">userTypeName,</if>
|
<if test="createtime != null">createtime,</if>
|
<if test="tkMktStatus != null">tkMktStatus,</if>
|
<if test="updatetime != null">updatetime,</if>
|
<if test="state != null">state,</if>
|
<if test="totalSales != null">totalSales,</if>
|
</trim>
|
values
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
<if test="id != null">#{id,jdbcType=BIGINT},</if>
|
<if test="rootCatId != null">#{rootCatId,jdbcType=INTEGER},</if>
|
<if test="eventCreatorId != null">#{eventCreatorId,jdbcType=INTEGER},</if>
|
<if test="leafCatId != null">#{leafCatId,jdbcType=INTEGER},</if>
|
<if test="debugInfo != null">#{debugInfo,jdbcType=VARCHAR},</if>
|
<if test="rootCatScore != null">#{rootCatScore,jdbcType=INTEGER},</if>
|
<if test="sellerId != null">#{sellerId,jdbcType=BIGINT},</if>
|
<if test="userType != null">#{userType,jdbcType=INTEGER},</if>
|
<if test="shopTitle != null">#{shopTitle,jdbcType=VARCHAR},</if>
|
<if test="pictUrl != null">#{pictUrl,jdbcType=VARCHAR},</if>
|
<if test="title != null">#{title,jdbcType=VARCHAR},</if>
|
<if test="auctionId != null">#{auctionId,jdbcType=BIGINT},</if>
|
<if test="couponLink != null">#{couponLink,jdbcType=VARCHAR},</if>
|
<if test="couponLinkTaoToken != null">#{couponLinkTaoToken,jdbcType=VARCHAR},</if>
|
<if test="couponActivityId != null">#{couponActivityId,jdbcType=VARCHAR},</if>
|
<if test="biz30day != null">#{biz30day,jdbcType=INTEGER},</if>
|
<if test="tkRate != null">#{tkRate,jdbcType=DECIMAL},</if>
|
<if test="nick != null">#{nick,jdbcType=VARCHAR},</if>
|
<if test="includeDxjh != null">#{includeDxjh,jdbcType=INTEGER},</if>
|
<if test="reservePrice != null">#{reservePrice,jdbcType=DECIMAL},</if>
|
<if test="tkCommFee != null">#{tkCommFee,jdbcType=DECIMAL},</if>
|
<if test="totalFee != null">#{totalFee,jdbcType=DECIMAL},</if>
|
<if test="totalNum != null">#{totalNum,jdbcType=INTEGER},</if>
|
<if test="zkPrice != null">#{zkPrice,jdbcType=DECIMAL},</if>
|
<if test="dayLeft != null">#{dayLeft,jdbcType=INTEGER},</if>
|
<if test="tk3rdRate != null">#{tk3rdRate,jdbcType=VARCHAR},</if>
|
<if test="auctionUrl != null">#{auctionUrl,jdbcType=VARCHAR},</if>
|
<if test="rlRate != null">#{rlRate,jdbcType=DECIMAL},</if>
|
<if test="hasRecommended != null">#{hasRecommended,jdbcType=INTEGER},</if>
|
<if test="hasSame != null">#{hasSame,jdbcType=INTEGER},</if>
|
<if test="sameItemPid != null">#{sameItemPid,jdbcType=BIGINT},</if>
|
<if test="couponTotalCount != null">#{couponTotalCount,jdbcType=INTEGER},</if>
|
<if test="couponLeftCount != null">#{couponLeftCount,jdbcType=INTEGER},</if>
|
<if test="couponAmount != null">#{couponAmount,jdbcType=DECIMAL},</if>
|
<if test="eventRate != null">#{eventRate,jdbcType=VARCHAR},</if>
|
<if test="couponShortLink != null">#{couponShortLink,jdbcType=VARCHAR},</if>
|
<if test="couponInfo != null">#{couponInfo,jdbcType=VARCHAR},</if>
|
<if test="couponStartFee != null">#{couponStartFee,jdbcType=DECIMAL},</if>
|
<if test="couponEffectiveStartTime != null">#{couponEffectiveStartTime,jdbcType=VARCHAR},</if>
|
<if test="couponEffectiveEndTime != null">#{couponEffectiveEndTime,jdbcType=VARCHAR},</if>
|
<if test="hasUmpBonus != null">#{hasUmpBonus,jdbcType=VARCHAR},</if>
|
<if test="isBizActivity != null">#{isBizActivity,jdbcType=VARCHAR},</if>
|
<if test="umpBonus != null">#{umpBonus,jdbcType=VARCHAR},</if>
|
<if test="rootCategoryName != null">#{rootCategoryName,jdbcType=VARCHAR},</if>
|
<if test="couponOriLink != null">#{couponOriLink,jdbcType=VARCHAR},</if>
|
<if test="userTypeName != null">#{userTypeName,jdbcType=VARCHAR},</if>
|
<if test="createtime != null">#{createtime,jdbcType=TIMESTAMP},</if>
|
<if test="tkMktStatus != null">#{tkMktStatus,jdbcType=VARCHAR},</if>
|
<if test="updatetime != null">#{updatetime,jdbcType=TIMESTAMP},</if>
|
<if test="state != null">#{state,jdbcType=INTEGER}</if>
|
<if test="totalSales != null">#{totalSales,jdbcType=INTEGER}</if>
|
</trim>
|
</insert>
|
<update id="updateByPrimaryKey" parameterType="com.yeshi.fanli.entity.taobao.TaoBaoGoodsBrief">update
|
yeshi_ec_taobao_goods set
|
rootCatId = #{rootCatId,jdbcType=INTEGER},
|
eventCreatorId = #{eventCreatorId,jdbcType=INTEGER},
|
leafCatId = #{leafCatId,jdbcType=INTEGER},
|
debugInfo = #{debugInfo,jdbcType=VARCHAR},
|
rootCatScore = #{rootCatScore,jdbcType=INTEGER},
|
sellerId = #{sellerId,jdbcType=BIGINT},
|
userType = #{userType,jdbcType=INTEGER},
|
shopTitle = #{shopTitle,jdbcType=VARCHAR},
|
pictUrl = #{pictUrl,jdbcType=VARCHAR},
|
title = #{title,jdbcType=VARCHAR},
|
auctionId = #{auctionId,jdbcType=BIGINT},
|
couponLink = #{couponLink,jdbcType=VARCHAR},
|
couponLinkTaoToken = #{couponLinkTaoToken,jdbcType=VARCHAR},
|
couponActivityId = #{couponActivityId,jdbcType=VARCHAR},
|
biz30day = #{biz30day,jdbcType=INTEGER},
|
tkRate = #{tkRate,jdbcType=DECIMAL},
|
nick = #{nick,jdbcType=VARCHAR},
|
includeDxjh = #{includeDxjh,jdbcType=INTEGER},
|
reservePrice = #{reservePrice,jdbcType=DECIMAL},
|
tkCommFee = #{tkCommFee,jdbcType=DECIMAL},
|
totalFee = #{totalFee,jdbcType=DECIMAL},
|
totalNum = #{totalNum,jdbcType=INTEGER},
|
zkPrice = #{zkPrice,jdbcType=DECIMAL},
|
dayLeft = #{dayLeft,jdbcType=INTEGER},
|
tk3rdRate = #{tk3rdRate,jdbcType=VARCHAR},
|
auctionUrl = #{auctionUrl,jdbcType=VARCHAR},
|
rlRate = #{rlRate,jdbcType=DECIMAL},
|
hasRecommended = #{hasRecommended,jdbcType=INTEGER},
|
hasSame = #{hasSame,jdbcType=INTEGER},
|
sameItemPid = #{sameItemPid,jdbcType=BIGINT},
|
couponTotalCount = #{couponTotalCount,jdbcType=INTEGER},
|
couponLeftCount = #{couponLeftCount,jdbcType=INTEGER},
|
couponAmount = #{couponAmount,jdbcType=DECIMAL},
|
eventRate = #{eventRate,jdbcType=VARCHAR},
|
couponShortLink = #{couponShortLink,jdbcType=VARCHAR},
|
couponInfo = #{couponInfo,jdbcType=VARCHAR},
|
couponStartFee = #{couponStartFee,jdbcType=DECIMAL},
|
couponEffectiveStartTime = #{couponEffectiveStartTime,jdbcType=VARCHAR},
|
couponEffectiveEndTime = #{couponEffectiveEndTime,jdbcType=VARCHAR},
|
hasUmpBonus = #{hasUmpBonus,jdbcType=VARCHAR},
|
isBizActivity = #{isBizActivity,jdbcType=VARCHAR},
|
umpBonus = #{umpBonus,jdbcType=VARCHAR},
|
rootCategoryName = #{rootCategoryName,jdbcType=VARCHAR},
|
]couponOriLink = #{couponOriLink,jdbcType=VARCHAR},
|
userTypeName = #{userTypeName,jdbcType=VARCHAR},
|
createtime = #{createtime,jdbcType=TIMESTAMP},
|
tkMktStatus = #{tkMktStatus,jdbcType=VARCHAR} ,
|
updatetime = #{updatetime,jdbcType=TIMESTAMP},
|
state =#{state,jdbcType=INTEGER},
|
totalSales =#{totalSales,jdbcType=INTEGER}
|
where id = #{id,jdbcType=BIGINT}
|
</update>
|
<update id="updateByPrimaryKeySelective" parameterType="com.yeshi.fanli.entity.taobao.TaoBaoGoodsBrief">
|
update yeshi_ec_taobao_goods
|
<set>
|
<if test="rootCatId != null">rootCatId=#{rootCatId,jdbcType=INTEGER},</if>
|
<if test="eventCreatorId != null">eventCreatorId=#{eventCreatorId,jdbcType=INTEGER},</if>
|
<if test="leafCatId != null">leafCatId=#{leafCatId,jdbcType=INTEGER},</if>
|
<if test="debugInfo != null">debugInfo=#{debugInfo,jdbcType=VARCHAR},</if>
|
<if test="rootCatScore != null">rootCatScore=#{rootCatScore,jdbcType=INTEGER},</if>
|
<if test="sellerId != null">sellerId=#{sellerId,jdbcType=BIGINT},</if>
|
<if test="userType != null">userType=#{userType,jdbcType=INTEGER},</if>
|
<if test="shopTitle != null">shopTitle=#{shopTitle,jdbcType=VARCHAR},</if>
|
<if test="pictUrl != null">pictUrl=#{pictUrl,jdbcType=VARCHAR},</if>
|
<if test="title != null">title=#{title,jdbcType=VARCHAR},</if>
|
<if test="auctionId != null">auctionId=#{auctionId,jdbcType=BIGINT},</if>
|
<if test="couponLink != null">couponLink=#{couponLink,jdbcType=VARCHAR},</if>
|
<if test="couponLinkTaoToken != null">couponLinkTaoToken=#{couponLinkTaoToken,jdbcType=VARCHAR},
|
</if>
|
<if test="couponActivityId != null">couponActivityId=#{couponActivityId,jdbcType=VARCHAR},
|
</if>
|
<if test="biz30day != null">biz30day=#{biz30day,jdbcType=INTEGER},</if>
|
<if test="tkRate != null">tkRate=#{tkRate,jdbcType=DECIMAL},</if>
|
<if test="nick != null">nick=#{nick,jdbcType=VARCHAR},</if>
|
<if test="includeDxjh != null">includeDxjh=#{includeDxjh,jdbcType=INTEGER},</if>
|
<if test="reservePrice != null">reservePrice=#{reservePrice,jdbcType=DECIMAL},</if>
|
<if test="tkCommFee != null">tkCommFee=#{tkCommFee,jdbcType=DECIMAL},</if>
|
<if test="totalFee != null">totalFee=#{totalFee,jdbcType=DECIMAL},</if>
|
<if test="totalNum != null">totalNum=#{totalNum,jdbcType=INTEGER},</if>
|
<if test="zkPrice != null">zkPrice=#{zkPrice,jdbcType=DECIMAL},</if>
|
<if test="dayLeft != null">dayLeft=#{dayLeft,jdbcType=INTEGER},</if>
|
<if test="tk3rdRate != null">tk3rdRate=#{tk3rdRate,jdbcType=VARCHAR},</if>
|
<if test="auctionUrl != null">auctionUrl=#{auctionUrl,jdbcType=VARCHAR},</if>
|
<if test="rlRate != null">rlRate=#{rlRate,jdbcType=DECIMAL},</if>
|
<if test="hasRecommended != null">hasRecommended=#{hasRecommended,jdbcType=INTEGER},</if>
|
<if test="hasSame != null">hasSame=#{hasSame,jdbcType=INTEGER},</if>
|
<if test="sameItemPid != null">sameItemPid=#{sameItemPid,jdbcType=BIGINT},</if>
|
<if test="couponTotalCount != null">couponTotalCount=#{couponTotalCount,jdbcType=INTEGER},
|
</if>
|
<if test="couponLeftCount != null">couponLeftCount=#{couponLeftCount,jdbcType=INTEGER},</if>
|
<if test="couponAmount != null">couponAmount=#{couponAmount,jdbcType=DECIMAL},</if>
|
<if test="eventRate != null">eventRate=#{eventRate,jdbcType=VARCHAR},</if>
|
<if test="couponShortLink != null">couponShortLink=#{couponShortLink,jdbcType=VARCHAR},</if>
|
<if test="couponInfo != null">couponInfo=#{couponInfo,jdbcType=VARCHAR},</if>
|
<if test="couponStartFee != null">couponStartFee=#{couponStartFee,jdbcType=DECIMAL},</if>
|
<if test="couponEffectiveStartTime != null">couponEffectiveStartTime=#{couponEffectiveStartTime,jdbcType=VARCHAR},
|
</if>
|
<if test="couponEffectiveEndTime != null">couponEffectiveEndTime=#{couponEffectiveEndTime,jdbcType=VARCHAR},
|
</if>
|
<if test="hasUmpBonus != null">hasUmpBonus=#{hasUmpBonus,jdbcType=VARCHAR},</if>
|
<if test="isBizActivity != null">isBizActivity=#{isBizActivity,jdbcType=VARCHAR},</if>
|
<if test="umpBonus != null">umpBonus=#{umpBonus,jdbcType=VARCHAR},</if>
|
<if test="rootCategoryName != null">rootCategoryName=#{rootCategoryName,jdbcType=VARCHAR},
|
</if>
|
<if test="couponOriLink != null">couponOriLink=#{couponOriLink,jdbcType=VARCHAR},</if>
|
<if test="userTypeName != null">userTypeName=#{userTypeName,jdbcType=VARCHAR},</if>
|
<if test="createtime != null">createtime=#{createtime,jdbcType=TIMESTAMP},</if>
|
<if test="tkMktStatus != null">tkMktStatus=#{tkMktStatus,jdbcType=VARCHAR},</if>
|
<if test="updatetime !=null">updatetime =#{updatetime,jdbcType=TIMESTAMP},</if>
|
<if test="state !=null">state =#{state,jdbcType=INTEGER},</if>
|
<if test="state !=null">totalSales =#{totalSales,jdbcType=INTEGER},</if>
|
</set>
|
where id = #{id,jdbcType=BIGINT}
|
</update>
|
<select id="queryByAuctionId" resultMap="BaseResultMap">
|
<!-- 根据auctionId 查询商品信息 -->
|
SELECT
|
<include refid="Base_Column_List" />
|
FROM yeshi_ec_taobao_goods tg WHERE tg.`auctionId` = ${auctionId}
|
</select>
|
<insert id="insertBatch" useGeneratedKeys="true" keyProperty="id"
|
parameterType="java.util.List">
|
insert into yeshi_ec_taobao_goods
|
(
|
<include refid="Base_Column_List" />
|
)
|
values
|
<foreach collection="list" item="item" separator=",">(
|
#{item.id,jdbcType=BIGINT},
|
#{item.rootCatId,jdbcType=INTEGER},
|
#{item.eventCreatorId,jdbcType=INTEGER},
|
#{item.leafCatId,jdbcType=INTEGER},
|
#{item.debugInfo,jdbcType=VARCHAR},
|
#{item.rootCatScore,jdbcType=INTEGER},
|
#{item.sellerId,jdbcType=BIGINT},
|
#{item.userType,jdbcType=INTEGER},
|
#{item.shopTitle,jdbcType=VARCHAR},
|
#{item.pictUrl,jdbcType=VARCHAR},
|
#{item.title,jdbcType=VARCHAR},
|
#{item.auctionId,jdbcType=BIGINT},
|
#{item.couponLink,jdbcType=VARCHAR},
|
#{item.couponLinkTaoToken,jdbcType=VARCHAR},
|
#{item.couponActivityId,jdbcType=VARCHAR},
|
#{item.biz30day,jdbcType=INTEGER},
|
#{item.tkRate,jdbcType=DECIMAL},
|
#{item.nick,jdbcType=VARCHAR},
|
#{item.includeDxjh,jdbcType=INTEGER},
|
#{item.reservePrice,jdbcType=DECIMAL},
|
#{item.tkCommFee,jdbcType=DECIMAL},
|
#{item.totalFee,jdbcType=DECIMAL},
|
#{item.totalNum,jdbcType=INTEGER},
|
#{item.zkPrice,jdbcType=DECIMAL},
|
#{item.dayLeft,jdbcType=INTEGER},
|
#{item.tk3rdRate,jdbcType=VARCHAR},
|
#{item.auctionUrl,jdbcType=VARCHAR},
|
#{item.rlRate,jdbcType=BIGINT},
|
#{item.hasRecommended,jdbcType=INTEGER},
|
#{item.hasSame,jdbcType=INTEGER},
|
#{item.sameItemPid,jdbcType=BIGINT},
|
#{item.couponTotalCount,jdbcType=INTEGER},
|
#{item.couponLeftCount,jdbcType=INTEGER},
|
#{item.couponAmount,jdbcType=DECIMAL},
|
#{item.eventRate,jdbcType=VARCHAR},
|
#{item.couponShortLink,jdbcType=VARCHAR},
|
#{item.couponInfo,jdbcType=VARCHAR},
|
#{item.couponStartFee,jdbcType=DECIMAL},
|
#{item.couponEffectiveStartTime,jdbcType=VARCHAR},
|
#{item.couponEffectiveEndTime,jdbcType=VARCHAR},
|
#{item.hasUmpBonus,jdbcType=VARCHAR},
|
#{item.isBizActivity,jdbcType=VARCHAR},
|
#{item.umpBonus,jdbcType=VARCHAR},
|
#{item.rootCategoryName,jdbcType=VARCHAR},
|
#{item.couponOriLink,jdbcType=VARCHAR},
|
#{item.userTypeName,jdbcType=VARCHAR},
|
#{item.createtime,jdbcType=TIMESTAMP},
|
#{item.tkMktStatus,jdbcType=VARCHAR},
|
#{item.updatetime,jdbcType=TIMESTAMP},
|
#{item.state,jdbcType=INTEGER},
|
#{item.totalSales,jdbcType=INTEGER}
|
)
|
</foreach>
|
</insert>
|
|
<select id="queryGoodsByAuctionId" resultMap="BaseResultMap">
|
<!-- 根据auctionId 查询商品信息 -->
|
SELECT
|
<include refid="Base_Column_List" />
|
FROM yeshi_ec_taobao_goods WHERE auctionId in
|
<foreach collection="list" item="item" open="(" close=")"
|
separator=",">#{item}</foreach>
|
ORDER BY id DESC
|
</select>
|
|
<update id="updateBatchSelective" parameterType="java.util.List">
|
|
update yeshi_ec_taobao_goods
|
<trim prefix="set" suffixOverrides=",">
|
|
<trim prefix="auctionUrl = case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.auctionUrl != null">
|
when id=#{item.id} then #{item.auctionUrl}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="title = case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.title != null">
|
when id=#{item.id} then #{item.title}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="pictUrl = case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.pictUrl != null">
|
when id=#{item.id} then #{item.pictUrl}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="reservePrice = case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.reservePrice != null">
|
when id=#{item.id} then #{item.reservePrice}
|
</if>
|
</foreach>
|
</trim>
|
|
|
<trim prefix="zkPrice =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.zkPrice != null">
|
when id=#{item.id} then #{item.zkPrice}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="biz30day =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.biz30day !=null">
|
when id=#{item.id} then #{item.biz30day}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="tkRate =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.tkRate !=null">
|
when id=#{item.id} then #{item.tkRate}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="eventRate =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.eventRate !=null">
|
when id=#{item.id} then #{item.eventRate}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="couponActivityId =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponActivityId !=null">
|
when id=#{item.id} then #{item.couponActivityId}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="couponLink =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponLink != null">
|
when id=#{item.id} then #{item.couponLink}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="couponTotalCount =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponTotalCount !=null">
|
when id=#{item.id} then #{item.couponTotalCount}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="couponLeftCount =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponLeftCount !=null">
|
when id=#{item.id} then #{item.couponLeftCount}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="couponAmount =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponAmount !=null">
|
when id=#{item.id} then #{item.couponAmount}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="couponInfo =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponInfo !=null">
|
when id=#{item.id} then #{item.couponInfo}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="couponStartFee =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponStartFee !=null">
|
when id=#{item.id} then #{item.couponStartFee}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="couponEffectiveStartTime =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponEffectiveStartTime !=null">
|
when id=#{item.id} then
|
#{item.couponEffectiveStartTime}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="couponEffectiveEndTime =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.couponEffectiveEndTime !=null">
|
when id=#{item.id} then #{item.couponEffectiveEndTime}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="shopTitle =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.shopTitle !=null">
|
when id=#{item.id} then #{item.shopTitle}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="sellerId =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.sellerId!=null">
|
when id=#{item.id} then #{item.sellerId}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="rootCatId =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.rootCatId!=null">
|
when id=#{item.id} then #{item.rootCatId}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="rootCategoryName =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.rootCategoryName!=null">
|
when id=#{item.id} then #{item.rootCategoryName}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="leafCatId =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.leafCatId!=null">
|
when id=#{item.id} then #{item.leafCatId}
|
</if>
|
</foreach>
|
</trim>
|
<trim prefix="state =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.state !=null">
|
when id=#{item.id} then #{item.state}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="totalSales =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.totalSales !=null">
|
when id=#{item.id} then #{item.totalSales}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="createtime =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.createtime !=null">
|
when id=#{item.id} then #{item.createtime}
|
</if>
|
</foreach>
|
</trim>
|
|
<trim prefix="updatetime =case" suffix="end,">
|
<foreach collection="list" item="item" index="index">
|
<if test="item.updatetime !=null">
|
when id=#{item.id} then #{item.updatetime}
|
</if>
|
</foreach>
|
</trim>
|
</trim>
|
where id in
|
<foreach collection="list" index="index" item="item"
|
separator="," open="(" close=")">
|
#{item.id,jdbcType=BIGINT}
|
</foreach>
|
</update>
|
|
|
</mapper>
|