|
@@ -16,19 +16,22 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectLSlideshowVo">
|
|
|
- select slideshow_id,slideshow_name, picture, create_time, create_by, update_time, update_by, remark from l_slideshow
|
|
|
+ select slideshow_id,slideshow_name, picture,slideshow_type,status,province_code,province_name,city_code,city_name,district_code,district_name, create_time, create_by, update_time, update_by, remark from l_slideshow
|
|
|
</sql>
|
|
|
|
|
|
<select id="selectLSlideshowList" parameterType="Slideshow" resultMap="LSlideshowResult">
|
|
|
- <include refid="selectLSlideshowVo"/>
|
|
|
- <where>
|
|
|
- <if test="picture != null and picture != ''"> and picture = #{picture}</if>
|
|
|
- </where>
|
|
|
+ select * from l_slideshow
|
|
|
</select>
|
|
|
|
|
|
- <select id="selectLSlideshowBySlideshowId" parameterType="Long" resultMap="LSlideshowResult">
|
|
|
- <include refid="selectLSlideshowVo"/>
|
|
|
- where slideshow_id = #{slideshowId}
|
|
|
+
|
|
|
+ <select id="selectLSlideshowBySlideshowType" resultType="com.leromro.core.domain.Slideshow">
|
|
|
+ select * from l_slideshow
|
|
|
+ where slideshow_type = #{slideshowType} and status = 1
|
|
|
+ </select>
|
|
|
+ <select id="selectDefultSlideshowByType" resultType="com.leromro.core.domain.Slideshow"
|
|
|
+ parameterType="java.lang.Long">
|
|
|
+ select * from l_slideshow
|
|
|
+ where slideshow_type = #{slideshowType} and area_id = 100 and status = 1
|
|
|
</select>
|
|
|
|
|
|
<insert id="insertLSlideshow" parameterType="Slideshow" useGeneratedKeys="true" keyProperty="slideshowId">
|
|
@@ -36,6 +39,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
<if test="slideshowName != null">slideshow_name,</if>
|
|
|
<if test="picture != null">picture,</if>
|
|
|
+ <if test="slideshowType != null">slideshow_type,</if>
|
|
|
+ <if test="status != null">status,</if>
|
|
|
+ <if test="provincecode != null">province_code,</if>
|
|
|
+ <if test="provinceName != null">province_name,</if>
|
|
|
+ <if test="cityCode != null">city_code,</if>
|
|
|
+ <if test="cityName != null">city_name,</if>
|
|
|
+ <if test="districtCode != null">district_code,</if>
|
|
|
+ <if test="districtName != null">district_name,</if>
|
|
|
<if test="createTime != null">create_time,</if>
|
|
|
<if test="createBy != null">create_by,</if>
|
|
|
<if test="updateTime != null">update_time,</if>
|
|
@@ -45,6 +56,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="slideshowName != null">#{slideshowName},</if>
|
|
|
<if test="picture != null">#{picture},</if>
|
|
|
+ <if test="slideshowType != null">#{slideshowType},</if>
|
|
|
+ <if test="status != null">#{status},</if>
|
|
|
+ <if test="provincecode != null">#{provincecode},</if>
|
|
|
+ <if test="provinceName != null">#{provinceName},</if>
|
|
|
+ <if test="cityCode != null">#{cityCode},</if>
|
|
|
+ <if test="cityName != null">#{cityName},</if>
|
|
|
+ <if test="districtCode != null">#{districtCode},</if>
|
|
|
+ <if test="districtName != null">#{districtName},</if>
|
|
|
<if test="createTime != null">#{createTime},</if>
|
|
|
<if test="createBy != null">#{createBy},</if>
|
|
|
<if test="updateTime != null">#{updateTime},</if>
|
|
@@ -77,4 +96,5 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
#{slideshowId}
|
|
|
</foreach>
|
|
|
</delete>
|
|
|
+
|
|
|
</mapper>
|