|
@@ -0,0 +1,540 @@
|
|
|
+<?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.caimei.www.mapper.CmBrandLandingMapper">
|
|
|
+
|
|
|
+ <resultMap type="CmBrandLanding" id="CmBrandLandingResult">
|
|
|
+ <result property="id" column="id" />
|
|
|
+ <result property="type" column="type" />
|
|
|
+ <result property="authUserId" column="authUserId" />
|
|
|
+ <result property="authorId" column="authorId" />
|
|
|
+ <result property="headPcBanner" column="headPcBanner" />
|
|
|
+ <result property="headAppBanner" column="headAppBanner" />
|
|
|
+ <result property="jumpStatus" column="jumpStatus" />
|
|
|
+ <result property="jumpPcPicture" column="jumpPcPicture" />
|
|
|
+ <result property="jumpAppPicture" column="jumpAppPicture" />
|
|
|
+ <result property="jumpLink" column="jumpLink" />
|
|
|
+ <result property="title" column="title" />
|
|
|
+ <result property="content" column="content" />
|
|
|
+ <result property="video" column="video" />
|
|
|
+ <result property="sort" column="sort" />
|
|
|
+ <result property="pcStatus" column="pcStatus" />
|
|
|
+ <result property="appStatus" column="appStatus" />
|
|
|
+ <result property="levelType" column="levelType" />
|
|
|
+ <result property="delFlag" column="delFlag" />
|
|
|
+ <result property="updateTime" column="updateTime" />
|
|
|
+ <result property="addTime" column="addTime" />
|
|
|
+ </resultMap>
|
|
|
+
|
|
|
+ <sql id="selectCmBrandLandingVo">
|
|
|
+ select
|
|
|
+ cm_brand_landing.id,
|
|
|
+ cm_brand_landing.type,
|
|
|
+ cm_brand_landing.authUserId,
|
|
|
+ cm_brand_landing.authorId,
|
|
|
+ cm_brand_landing.headPcBanner,
|
|
|
+ cm_brand_landing.headAppBanner,
|
|
|
+ cm_brand_landing.jumpStatus,
|
|
|
+ cm_brand_landing.jumpPcPicture,
|
|
|
+ cm_brand_landing.jumpAppPicture,
|
|
|
+ cm_brand_landing.jumpLink,
|
|
|
+ cm_brand_landing.title,
|
|
|
+ cm_brand_landing.content,
|
|
|
+ cm_brand_landing.video,
|
|
|
+ cm_brand_landing.sort,
|
|
|
+ cm_brand_landing.pcStatus,
|
|
|
+ cm_brand_landing.appStatus,
|
|
|
+ cm_brand_landing.levelType,
|
|
|
+ cm_brand_landing.delFlag,
|
|
|
+ cm_brand_landing.updateTime,
|
|
|
+ cm_brand_landing.addTime
|
|
|
+ </sql>
|
|
|
+
|
|
|
+ <select id="getByCmBrandLanding" parameterType="CmBrandLanding" resultMap="CmBrandLandingResult">
|
|
|
+ <include refid="selectCmBrandLandingVo"/>
|
|
|
+ from cm_brand_landing AS cm_brand_landing
|
|
|
+ <where> cm_brand_landing.delFlag = 0
|
|
|
+ <if test="id != null and id != ''">
|
|
|
+ and cm_brand_landing.id
|
|
|
+ <if test="id.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{id}
|
|
|
+ </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="id.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="idIn" collection="id.substring(id.toUpperCase().indexOf('=')+1,id.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{idIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="type != null and type != ''">
|
|
|
+ and cm_brand_landing.type
|
|
|
+ <if test="type.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{type}
|
|
|
+ </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="type.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="type.substring(type.toUpperCase().indexOf('=')+1,type.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="authUserId != null "> and cm_brand_landing.authUserId = #{authUserId}</if>
|
|
|
+ <if test="authorId != null and authorId != ''"> and cm_brand_landing.authorId = #{authorId}</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''"> and cm_brand_landing.headPcBanner = #{headPcBanner}</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''"> and cm_brand_landing.headAppBanner = #{headAppBanner}</if>
|
|
|
+ <if test="jumpStatus != null "> and cm_brand_landing.jumpStatus = #{jumpStatus}</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''"> and cm_brand_landing.jumpPcPicture = #{jumpPcPicture}</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''"> and cm_brand_landing.jumpAppPicture = #{jumpAppPicture}</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''"> and cm_brand_landing.jumpLink = #{jumpLink}</if>
|
|
|
+ <if test="title != null and title != ''"> and cm_brand_landing.title = #{title}</if>
|
|
|
+ <if test="content != null and content != ''"> and cm_brand_landing.content = #{content}</if>
|
|
|
+ <if test="video != null and video != ''"> and cm_brand_landing.video = #{video}</if>
|
|
|
+ <if test="sort != null "> and cm_brand_landing.sort = #{sort}</if>
|
|
|
+ <if test="pcStatus != null "> and cm_brand_landing.pcStatus = #{pcStatus}</if>
|
|
|
+ <if test="appStatus != null "> and cm_brand_landing.appStatus = #{appStatus}</if>
|
|
|
+ <if test="levelType != null and levelType != ''">
|
|
|
+ and cm_brand_landing.levelType
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{levelType}
|
|
|
+ </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="levelType.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="levelType.substring(levelType.toUpperCase().indexOf('=')+1,levelType.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="delFlag != null "> and cm_brand_landing.delFlag = #{delFlag}</if>
|
|
|
+ <if test="updateTime != null "> and cm_brand_landing.updateTime = #{updateTime}</if>
|
|
|
+ <if test="addTime != null "> and cm_brand_landing.addTime = #{addTime}</if>
|
|
|
+ </where>
|
|
|
+ group by cm_brand_landing.id
|
|
|
+ order by cm_brand_landing.createTime desc
|
|
|
+ limit 0,1
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="getCmBrandLandingList" parameterType="CmBrandLandingVO" resultMap="CmBrandLandingResult">
|
|
|
+ <include refid="selectCmBrandLandingVo"/>
|
|
|
+ from cm_brand_landing AS cm_brand_landing
|
|
|
+ <where> cm_brand_landing.delFlag = 0
|
|
|
+ <if test="id != null and id != ''">
|
|
|
+ and cm_brand_landing.id
|
|
|
+ <if test="id.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{id}
|
|
|
+ </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="id.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="idIn" collection="id.substring(id.toUpperCase().indexOf('=')+1,id.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{idIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="type != null and type != ''">
|
|
|
+ and cm_brand_landing.type
|
|
|
+ <if test="type.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{type}
|
|
|
+ </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="type.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="type.substring(type.toUpperCase().indexOf('=')+1,type.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="authUserId != null "> and cm_brand_landing.authUserId = #{authUserId}</if>
|
|
|
+ <if test="authorId != null and authorId != ''"> and cm_brand_landing.authorId = #{authorId}</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''"> and cm_brand_landing.headPcBanner = #{headPcBanner}</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''"> and cm_brand_landing.headAppBanner = #{headAppBanner}</if>
|
|
|
+ <if test="jumpStatus != null "> and cm_brand_landing.jumpStatus = #{jumpStatus}</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''"> and cm_brand_landing.jumpPcPicture = #{jumpPcPicture}</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''"> and cm_brand_landing.jumpAppPicture = #{jumpAppPicture}</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''"> and cm_brand_landing.jumpLink = #{jumpLink}</if>
|
|
|
+ <if test="title != null and title != ''"> and cm_brand_landing.title = #{title}</if>
|
|
|
+ <if test="content != null and content != ''"> and cm_brand_landing.content = #{content}</if>
|
|
|
+ <if test="video != null and video != ''"> and cm_brand_landing.video = #{video}</if>
|
|
|
+ <if test="sort != null "> and cm_brand_landing.sort = #{sort}</if>
|
|
|
+ <if test="pcStatus != null "> and cm_brand_landing.pcStatus = #{pcStatus}</if>
|
|
|
+ <if test="appStatus != null "> and cm_brand_landing.appStatus = #{appStatus}</if>
|
|
|
+ <if test="levelType != null and levelType != ''">
|
|
|
+ and cm_brand_landing.levelType
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{levelType}
|
|
|
+ </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="levelType.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="levelType.substring(levelType.toUpperCase().indexOf('=')+1,levelType.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="delFlag != null "> and cm_brand_landing.delFlag = #{delFlag}</if>
|
|
|
+ <if test="updateTime != null "> and cm_brand_landing.updateTime = #{updateTime}</if>
|
|
|
+ <if test="addTime != null "> and cm_brand_landing.addTime = #{addTime}</if>
|
|
|
+ </where>
|
|
|
+ group by cm_brand_landing.id
|
|
|
+ order by cm_brand_landing.createTime desc
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="getCmBrandLandingCount" parameterType="CmBrandLanding" resultType="String">
|
|
|
+ select count(1)
|
|
|
+ from cm_brand_landing AS cm_brand_landing
|
|
|
+ <where> cm_brand_landing.delFlag = 0
|
|
|
+ <if test="id != null and id != ''">
|
|
|
+ and cm_brand_landing.id
|
|
|
+ <if test="id.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{id}
|
|
|
+ </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="id.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="idIn" collection="id.substring(id.toUpperCase().indexOf('=')+1,id.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{idIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="type != null and type != ''">
|
|
|
+ and cm_brand_landing.type
|
|
|
+ <if test="type.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{type}
|
|
|
+ </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="type.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="type.substring(type.toUpperCase().indexOf('=')+1,type.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="authUserId != null "> and cm_brand_landing.authUserId = #{authUserId}</if>
|
|
|
+ <if test="authorId != null and authorId != ''"> and cm_brand_landing.authorId = #{authorId}</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''"> and cm_brand_landing.headPcBanner = #{headPcBanner}</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''"> and cm_brand_landing.headAppBanner = #{headAppBanner}</if>
|
|
|
+ <if test="jumpStatus != null "> and cm_brand_landing.jumpStatus = #{jumpStatus}</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''"> and cm_brand_landing.jumpPcPicture = #{jumpPcPicture}</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''"> and cm_brand_landing.jumpAppPicture = #{jumpAppPicture}</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''"> and cm_brand_landing.jumpLink = #{jumpLink}</if>
|
|
|
+ <if test="title != null and title != ''"> and cm_brand_landing.title = #{title}</if>
|
|
|
+ <if test="content != null and content != ''"> and cm_brand_landing.content = #{content}</if>
|
|
|
+ <if test="video != null and video != ''"> and cm_brand_landing.video = #{video}</if>
|
|
|
+ <if test="sort != null "> and cm_brand_landing.sort = #{sort}</if>
|
|
|
+ <if test="pcStatus != null "> and cm_brand_landing.pcStatus = #{pcStatus}</if>
|
|
|
+ <if test="appStatus != null "> and cm_brand_landing.appStatus = #{appStatus}</if>
|
|
|
+ <if test="levelType != null and levelType != ''">
|
|
|
+ and cm_brand_landing.levelType
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{levelType}
|
|
|
+ </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="levelType.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="levelType.substring(levelType.toUpperCase().indexOf('=')+1,levelType.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="delFlag != null "> and cm_brand_landing.delFlag = #{delFlag}</if>
|
|
|
+ <if test="updateTime != null "> and cm_brand_landing.updateTime = #{updateTime}</if>
|
|
|
+ <if test="addTime != null "> and cm_brand_landing.addTime = #{addTime}</if>
|
|
|
+ </where>
|
|
|
+ group by cm_brand_landing.id
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="getCmBrandLandingById" parameterType="String" resultMap="CmBrandLandingResult">
|
|
|
+ <include refid="selectCmBrandLandingVo"/>
|
|
|
+ from cm_brand_landing AS cm_brand_landing
|
|
|
+ where cm_brand_landing.delFlag = 0 and cm_brand_landing.id = #{id}
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="getByIds" parameterType="CmBrandLanding" resultType="String">
|
|
|
+ select id
|
|
|
+ from cm_brand_landing AS cm_brand_landing
|
|
|
+ <where> cm_brand_landing.delFlag = 0
|
|
|
+ <if test="id != null and id != ''">
|
|
|
+ and cm_brand_landing.id
|
|
|
+ <if test="id.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{id}
|
|
|
+ </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="id.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="idIn" collection="id.substring(id.toUpperCase().indexOf('=')+1,id.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{idIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="type != null and type != ''">
|
|
|
+ and cm_brand_landing.type
|
|
|
+ <if test="type.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{type}
|
|
|
+ </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="type.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="type.substring(type.toUpperCase().indexOf('=')+1,type.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="authUserId != null "> and cm_brand_landing.authUserId = #{authUserId}</if>
|
|
|
+ <if test="authorId != null and authorId != ''"> and cm_brand_landing.authorId = #{authorId}</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''"> and cm_brand_landing.headPcBanner = #{headPcBanner}</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''"> and cm_brand_landing.headAppBanner = #{headAppBanner}</if>
|
|
|
+ <if test="jumpStatus != null "> and cm_brand_landing.jumpStatus = #{jumpStatus}</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''"> and cm_brand_landing.jumpPcPicture = #{jumpPcPicture}</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''"> and cm_brand_landing.jumpAppPicture = #{jumpAppPicture}</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''"> and cm_brand_landing.jumpLink = #{jumpLink}</if>
|
|
|
+ <if test="title != null and title != ''"> and cm_brand_landing.title = #{title}</if>
|
|
|
+ <if test="content != null and content != ''"> and cm_brand_landing.content = #{content}</if>
|
|
|
+ <if test="video != null and video != ''"> and cm_brand_landing.video = #{video}</if>
|
|
|
+ <if test="sort != null "> and cm_brand_landing.sort = #{sort}</if>
|
|
|
+ <if test="pcStatus != null "> and cm_brand_landing.pcStatus = #{pcStatus}</if>
|
|
|
+ <if test="appStatus != null "> and cm_brand_landing.appStatus = #{appStatus}</if>
|
|
|
+ <if test="levelType != null and levelType != ''">
|
|
|
+ and cm_brand_landing.levelType
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{levelType}
|
|
|
+ </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="levelType.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="levelType.substring(levelType.toUpperCase().indexOf('=')+1,levelType.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="delFlag != null "> and cm_brand_landing.delFlag = #{delFlag}</if>
|
|
|
+ <if test="updateTime != null "> and cm_brand_landing.updateTime = #{updateTime}</if>
|
|
|
+ <if test="addTime != null "> and cm_brand_landing.addTime = #{addTime}</if>
|
|
|
+ </where>
|
|
|
+ group by cm_brand_landing.id
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="getById" parameterType="CmBrandLanding" resultType="String">
|
|
|
+ select id
|
|
|
+ from cm_brand_landing AS cm_brand_landing
|
|
|
+ <where> cm_brand_landing.delFlag = 0
|
|
|
+ <if test="id != null and id != ''">
|
|
|
+ and cm_brand_landing.id
|
|
|
+ <if test="id.toString().toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{id}
|
|
|
+ </if>
|
|
|
+ <if test="id.toString().toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="id.toString().toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="id.toString().toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="idIn" collection="id.toString().substring(id.toString().toUpperCase().indexOf('=')+1,id.toString().length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{idIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="type != null and type != ''">
|
|
|
+ and cm_brand_landing.type
|
|
|
+ <if test="type.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{type}
|
|
|
+ </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="type.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="type.substring(type.toUpperCase().indexOf('=')+1,type.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="authUserId != null "> and cm_brand_landing.authUserId = #{authUserId}</if>
|
|
|
+ <if test="authorId != null and authorId != ''"> and cm_brand_landing.authorId = #{authorId}</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''"> and cm_brand_landing.headPcBanner = #{headPcBanner}</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''"> and cm_brand_landing.headAppBanner = #{headAppBanner}</if>
|
|
|
+ <if test="jumpStatus != null "> and cm_brand_landing.jumpStatus = #{jumpStatus}</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''"> and cm_brand_landing.jumpPcPicture = #{jumpPcPicture}</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''"> and cm_brand_landing.jumpAppPicture = #{jumpAppPicture}</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''"> and cm_brand_landing.jumpLink = #{jumpLink}</if>
|
|
|
+ <if test="title != null and title != ''"> and cm_brand_landing.title = #{title}</if>
|
|
|
+ <if test="content != null and content != ''"> and cm_brand_landing.content = #{content}</if>
|
|
|
+ <if test="video != null and video != ''"> and cm_brand_landing.video = #{video}</if>
|
|
|
+ <if test="sort != null "> and cm_brand_landing.sort = #{sort}</if>
|
|
|
+ <if test="pcStatus != null "> and cm_brand_landing.pcStatus = #{pcStatus}</if>
|
|
|
+ <if test="appStatus != null "> and cm_brand_landing.appStatus = #{appStatus}</if>
|
|
|
+ <if test="levelType != null and levelType != ''">
|
|
|
+ and cm_brand_landing.levelType
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{levelType}
|
|
|
+ </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="levelType.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="levelType.substring(levelType.toUpperCase().indexOf('=')+1,levelType.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="delFlag != null "> and cm_brand_landing.delFlag = #{delFlag}</if>
|
|
|
+ <if test="updateTime != null "> and cm_brand_landing.updateTime = #{updateTime}</if>
|
|
|
+ <if test="addTime != null "> and cm_brand_landing.addTime = #{addTime}</if>
|
|
|
+ </where>
|
|
|
+ group by cm_brand_landing.id
|
|
|
+ limit 0,1
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <insert id="addCmBrandLanding" parameterType="CmBrandLanding" useGeneratedKeys="true" keyProperty="id">
|
|
|
+ insert into cm_brand_landing
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="id != null and id != ''">id,</if>
|
|
|
+ <if test="type != null and type != ''">type,</if>
|
|
|
+ <if test="authUserId != null">authUserId,</if>
|
|
|
+ <if test="authorId != null and authorId != ''">authorId,</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''">headPcBanner,</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''">headAppBanner,</if>
|
|
|
+ <if test="jumpStatus != null">jumpStatus,</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''">jumpPcPicture,</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''">jumpAppPicture,</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''">jumpLink,</if>
|
|
|
+ <if test="title != null and title != ''">title,</if>
|
|
|
+ <if test="content != null and content != ''">content,</if>
|
|
|
+ <if test="video != null and video != ''">video,</if>
|
|
|
+ <if test="sort != null">sort,</if>
|
|
|
+ <if test="pcStatus != null">pcStatus,</if>
|
|
|
+ <if test="appStatus != null">appStatus,</if>
|
|
|
+ <if test="levelType != null and levelType != ''">levelType,</if>
|
|
|
+ <if test="delFlag != null">delFlag,</if>
|
|
|
+ <if test="updateTime != null">updateTime,</if>
|
|
|
+ <if test="addTime != null">addTime,</if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="id != null and id != ''">#{id},</if>
|
|
|
+ <if test="type != null and type != ''">#{type},</if>
|
|
|
+ <if test="authUserId != null">#{authUserId},</if>
|
|
|
+ <if test="authorId != null and authorId != ''">#{authorId},</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''">#{headPcBanner},</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''">#{headAppBanner},</if>
|
|
|
+ <if test="jumpStatus != null">#{jumpStatus},</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''">#{jumpPcPicture},</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''">#{jumpAppPicture},</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''">#{jumpLink},</if>
|
|
|
+ <if test="title != null and title != ''">#{title},</if>
|
|
|
+ <if test="content != null and content != ''">#{content},</if>
|
|
|
+ <if test="video != null and video != ''">#{video},</if>
|
|
|
+ <if test="sort != null">#{sort},</if>
|
|
|
+ <if test="pcStatus != null">#{pcStatus},</if>
|
|
|
+ <if test="appStatus != null">#{appStatus},</if>
|
|
|
+ <if test="levelType != null and levelType != ''">#{levelType},</if>
|
|
|
+ <if test="delFlag != null">#{delFlag},</if>
|
|
|
+ <if test="updateTime != null">#{updateTime},</if>
|
|
|
+ <if test="addTime != null">#{addTime},</if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+
|
|
|
+ <update id="updateCmBrandLanding" parameterType="CmBrandLanding">
|
|
|
+ update cm_brand_landing
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
+ <if test="type != null and type != ''">type = #{type},</if>
|
|
|
+ <if test="authUserId != null">authUserId = #{authUserId},</if>
|
|
|
+ <if test="authorId != null and authorId != ''">authorId = #{authorId},</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''">headPcBanner = #{headPcBanner},</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''">headAppBanner = #{headAppBanner},</if>
|
|
|
+ <if test="jumpStatus != null">jumpStatus = #{jumpStatus},</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''">jumpPcPicture = #{jumpPcPicture},</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''">jumpAppPicture = #{jumpAppPicture},</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''">jumpLink = #{jumpLink},</if>
|
|
|
+ <if test="title != null and title != ''">title = #{title},</if>
|
|
|
+ <if test="content != null and content != ''">content = #{content},</if>
|
|
|
+ <if test="video != null and video != ''">video = #{video},</if>
|
|
|
+ <if test="sort != null">sort = #{sort},</if>
|
|
|
+ <if test="pcStatus != null">pcStatus = #{pcStatus},</if>
|
|
|
+ <if test="appStatus != null">appStatus = #{appStatus},</if>
|
|
|
+ <if test="levelType != null and levelType != ''">levelType = #{levelType},</if>
|
|
|
+ <if test="delFlag != null">delFlag = #{delFlag},</if>
|
|
|
+ <if test="updateTime != null">updateTime = #{updateTime},</if>
|
|
|
+ <if test="addTime != null">addTime = #{addTime},</if>
|
|
|
+ </trim>
|
|
|
+ where id = #{id}
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <update id="updateDelCmBrandLandingByIds" parameterType="String">
|
|
|
+ update cm_brand_landing set delFlag=#{delFlag} where id in
|
|
|
+ <foreach item="id" collection="ids" open="(" separator="," close=")">
|
|
|
+ #{id}
|
|
|
+ </foreach>
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <delete id="delCmBrandLandingById" parameterType="String">
|
|
|
+ delete
|
|
|
+ from cm_brand_landing where id = #{id}
|
|
|
+ </delete>
|
|
|
+
|
|
|
+ <delete id="delCmBrandLanding" parameterType="CmBrandLanding">
|
|
|
+ delete
|
|
|
+ from cm_brand_landing AS cm_brand_landing
|
|
|
+ <where>
|
|
|
+ <if test="id != null and id != ''">
|
|
|
+ and cm_brand_landing.id
|
|
|
+ <if test="id.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{id}
|
|
|
+ </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="id.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="id.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="idIn" collection="id.substring(id.toUpperCase().indexOf('=')+1,id.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{idIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="type != null and type != ''">
|
|
|
+ and cm_brand_landing.type
|
|
|
+ <if test="type.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{type}
|
|
|
+ </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="type.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="type.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="type.substring(type.toUpperCase().indexOf('=')+1,type.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="authUserId != null "> and cm_brand_landing.authUserId = #{authUserId}</if>
|
|
|
+ <if test="authorId != null and authorId != ''"> and cm_brand_landing.authorId = #{authorId}</if>
|
|
|
+ <if test="headPcBanner != null and headPcBanner != ''"> and cm_brand_landing.headPcBanner = #{headPcBanner}</if>
|
|
|
+ <if test="headAppBanner != null and headAppBanner != ''"> and cm_brand_landing.headAppBanner = #{headAppBanner}</if>
|
|
|
+ <if test="jumpStatus != null "> and cm_brand_landing.jumpStatus = #{jumpStatus}</if>
|
|
|
+ <if test="jumpPcPicture != null and jumpPcPicture != ''"> and cm_brand_landing.jumpPcPicture = #{jumpPcPicture}</if>
|
|
|
+ <if test="jumpAppPicture != null and jumpAppPicture != ''"> and cm_brand_landing.jumpAppPicture = #{jumpAppPicture}</if>
|
|
|
+ <if test="jumpLink != null and jumpLink != ''"> and cm_brand_landing.jumpLink = #{jumpLink}</if>
|
|
|
+ <if test="title != null and title != ''"> and cm_brand_landing.title = #{title}</if>
|
|
|
+ <if test="content != null and content != ''"> and cm_brand_landing.content = #{content}</if>
|
|
|
+ <if test="video != null and video != ''"> and cm_brand_landing.video = #{video}</if>
|
|
|
+ <if test="sort != null "> and cm_brand_landing.sort = #{sort}</if>
|
|
|
+ <if test="pcStatus != null "> and cm_brand_landing.pcStatus = #{pcStatus}</if>
|
|
|
+ <if test="appStatus != null "> and cm_brand_landing.appStatus = #{appStatus}</if>
|
|
|
+ <if test="levelType != null and levelType != ''">
|
|
|
+ and cm_brand_landing.levelType
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')==-1">
|
|
|
+ = #{levelType}
|
|
|
+ </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('=')!=-1">
|
|
|
+ <if test="levelType.toUpperCase().indexOf('NOT')!=-1"> not </if>
|
|
|
+ <if test="levelType.toUpperCase().indexOf('IN')!=-1"> in </if>
|
|
|
+ <foreach item="typeIn" collection="levelType.substring(levelType.toUpperCase().indexOf('=')+1,levelType.length()).trim().split(',')" open="(" separator="," close=")">
|
|
|
+ #{typeIn}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ <if test="delFlag != null "> and cm_brand_landing.delFlag = #{delFlag}</if>
|
|
|
+ <if test="updateTime != null "> and cm_brand_landing.updateTime = #{updateTime}</if>
|
|
|
+ <if test="addTime != null "> and cm_brand_landing.addTime = #{addTime}</if>
|
|
|
+ </where>
|
|
|
+ </delete>
|
|
|
+
|
|
|
+ <delete id="delCmBrandLandingByIds" parameterType="String">
|
|
|
+ delete from cm_brand_landing where id in
|
|
|
+ <foreach item="id" collection="ids" open="(" separator="," close=")">
|
|
|
+ #{id}
|
|
|
+ </foreach>
|
|
|
+ </delete>
|
|
|
+
|
|
|
+</mapper>
|