|
@@ -15,6 +15,9 @@
|
|
|
<result column="name" property="name"/>
|
|
|
<result column="price" property="price"/>
|
|
|
<result column="intro" property="intro"/>
|
|
|
+ <result column="listDisplayImage" property="listDisplayImage"/>
|
|
|
+ <result column="rotatingImages" property="rotatingImages"/>
|
|
|
+ <result column="detailedImage" property="detailedImage"/>
|
|
|
</resultMap>
|
|
|
|
|
|
<select id="get" resultMap="result">
|
|
@@ -89,7 +92,8 @@
|
|
|
</select>
|
|
|
|
|
|
<insert id="save" useGeneratedKeys="true" keyProperty="id">
|
|
|
- INSERT INTO workark_product (organizationId, type, productLevelId, createTime, name, price, intro) VALUES (#{organizationId}, #{type}, #{productLevelId}, now(), #{name}, #{price}, #{intro})
|
|
|
+ INSERT INTO workark_product (organizationId, type, productLevelId, createTime, name, price, intro, listDisplayImage, rotatingImages, detailedImage)
|
|
|
+ VALUES (#{organizationId}, #{type}, #{productLevelId}, now(), #{name}, #{price}, #{intro}, #{listDisplayImage}, #{rotatingImages}, #{detailedImage})
|
|
|
</insert>
|
|
|
|
|
|
<update id="update" parameterType="com.bosshand.virgo.api.workark.model.Product">
|
|
@@ -103,6 +107,9 @@
|
|
|
<if test="intro!=null">intro=#{intro},</if>
|
|
|
<if test="updateTime==null">updateTime=now(),</if>
|
|
|
<if test="state!=null">state=#{state},</if>
|
|
|
+ <if test="listDisplayImage!=null">listDisplayImage=#{listDisplayImage},</if>
|
|
|
+ <if test="rotatingImages!=null">rotatingImages=#{rotatingImages},</if>
|
|
|
+ <if test="detailedImage!=null">detailedImage=#{detailedImage},</if>
|
|
|
</trim>
|
|
|
WHERE id=#{id}
|
|
|
</update>
|