| | |
| | | <result column="an_md5" property="md5" jdbcType="VARCHAR" />
|
| | | <result column="an_createtime" property="createTime" jdbcType="TIMESTAMP" />
|
| | | <result column="an_updatetime" property="updateTime" jdbcType="TIMESTAMP" />
|
| | | <result column="an_begin_time" property="beginTime" jdbcType="TIMESTAMP"/>
|
| | | <result column="an_end_time" property="endTime" jdbcType="TIMESTAMP"/>
|
| | | </resultMap>
|
| | | <sql id="Base_Column_List">an_id,an_type,an_show,an_can_close,an_content,an_content_url,an_md5,an_createtime,an_updatetime
|
| | | <sql id="Base_Column_List">an_id,an_type,an_show,an_can_close,an_content,an_content_url,an_md5,an_createtime,an_begin_time,an_end_time,an_updatetime
|
| | | </sql>
|
| | | <select id="selectByPrimaryKey" resultMap="BaseResultMap"
|
| | | parameterType="java.lang.Long">
|
| | |
| | | from yeshi_ec_apppage_notification where an_type = #{0}
|
| | | </select>
|
| | |
|
| | |
|
| | | <select id="listValidByType" resultMap="BaseResultMap" parameterType="java.lang.String">
|
| | | SELECT <include refid="Base_Column_List" /> FROM yeshi_ec_apppage_notification |
| | | WHERE an_type = #{0} AND an_show = 1 |
| | | AND IF(an_begin_time IS NULL,TRUE, an_begin_time<![CDATA[<=]]> NOW()) |
| | | AND IF(an_end_time IS NULL,TRUE, an_end_time <![CDATA[>=]]> NOW())
|
| | | </select>
|
| | |
|
| | |
|
| | | <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">delete from
|
| | |
| | | <insert id="insert" parameterType="com.yeshi.fanli.entity.bus.help.AppPageNotification"
|
| | | useGeneratedKeys="true" keyProperty="id">insert into
|
| | | yeshi_ec_apppage_notification
|
| | | (an_id,an_type,an_show,an_can_close,an_content,an_content_url,an_md5,an_createtime,an_updatetime)
|
| | | (an_id,an_type,an_show,an_can_close,an_content,an_content_url,an_md5,an_createtime,an_begin_time,an_end_time,an_updatetime)
|
| | | values
|
| | | (#{id,jdbcType=BIGINT},#{type,jdbcType=VARCHAR},#{show,jdbcType=BOOLEAN},#{canClose,jdbcType=BOOLEAN},#{content,jdbcType=VARCHAR},#{contentUrl,jdbcType=VARCHAR},#{md5,jdbcType=VARCHAR},#{createTime,jdbcType=TIMESTAMP},#{updateTime,jdbcType=TIMESTAMP})
|
| | | (#{id,jdbcType=BIGINT},#{type,jdbcType=VARCHAR},#{show,jdbcType=BOOLEAN},#{canClose,jdbcType=BOOLEAN},#{content,jdbcType=VARCHAR},#{contentUrl,jdbcType=VARCHAR},#{md5,jdbcType=VARCHAR},#{createTime,jdbcType=TIMESTAMP},#{beginTime,jdbcType=TIMESTAMP},#{endTime,jdbcType=TIMESTAMP},#{updateTime,jdbcType=TIMESTAMP})
|
| | | </insert>
|
| | | <insert id="insertSelective" parameterType="com.yeshi.fanli.entity.bus.help.AppPageNotification"
|
| | | useGeneratedKeys="true" keyProperty="id">
|
| | |
| | | <if test="contentUrl != null">an_content_url,</if>
|
| | | <if test="md5 != null">an_md5,</if>
|
| | | <if test="createTime != null">an_createtime,</if>
|
| | | <if test="beginTime != null">an_begin_time,</if>
|
| | | <if test="endTime != null">an_end_time,</if>
|
| | | <if test="updateTime != null">an_updatetime,</if>
|
| | | </trim>
|
| | | values
|
| | |
| | | <if test="contentUrl != null">#{contentUrl,jdbcType=VARCHAR},</if>
|
| | | <if test="md5 != null">#{md5,jdbcType=VARCHAR},</if>
|
| | | <if test="createTime != null">#{createTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="beginTime != null">#{beginTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="endTime != null">#{endTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="updateTime != null">#{updateTime,jdbcType=TIMESTAMP},</if>
|
| | | </trim>
|
| | | </insert>
|
| | |
| | | #{content,jdbcType=VARCHAR},an_content_url =
|
| | | #{contentUrl,jdbcType=VARCHAR},an_md5 =
|
| | | #{md5,jdbcType=VARCHAR},an_createtime =
|
| | | #{createTime,jdbcType=TIMESTAMP},an_updatetime =
|
| | | #{createTime,jdbcType=TIMESTAMP},an_begin_time = #{beginTime,jdbcType=TIMESTAMP},an_end_time = #{endTime,jdbcType=TIMESTAMP},an_updatetime =
|
| | | #{updateTime,jdbcType=TIMESTAMP} where an_id = #{id,jdbcType=BIGINT}
|
| | | </update>
|
| | | <update id="updateByPrimaryKeySelective" parameterType="com.yeshi.fanli.entity.bus.help.AppPageNotification">
|
| | |
| | | <if test="contentUrl != null">an_content_url=#{contentUrl,jdbcType=VARCHAR},</if>
|
| | | <if test="md5 != null">an_md5=#{md5,jdbcType=VARCHAR},</if>
|
| | | <if test="createTime != null">an_createtime=#{createTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="beginTime != null">an_begin_time=#{beginTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="endTime != null">an_end_time=#{endTime,jdbcType=TIMESTAMP},</if>
|
| | | <if test="updateTime != null">an_updatetime=#{updateTime,jdbcType=TIMESTAMP},</if>
|
| | | </set>
|
| | | where an_id = #{id,jdbcType=BIGINT}
|