|
|
@@ -17,6 +17,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="liveAdress" column="live_adress"/>
|
|
|
<result property="createTime" column="create_time"/>
|
|
|
<result property="updateTime" column="update_time"/>
|
|
|
+ <result property="activityLogo" column="activity_logo"/>
|
|
|
+ <result property="activityUrl" column="activity_url"/>
|
|
|
<result property="status" column="status"/>
|
|
|
</resultMap>
|
|
|
|
|
|
@@ -34,6 +36,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="createTime" column="create_time"/>
|
|
|
<result property="updateTime" column="update_time"/>
|
|
|
<result property="status" column="status"/>
|
|
|
+ <result property="activityLogo" column="activity_logo"/>
|
|
|
+ <result property="activityUrl" column="activity_url"/>
|
|
|
<collection property="courses" javaType="java.util.List" resultMap="CourseResult"/>
|
|
|
</resultMap>
|
|
|
|
|
|
@@ -101,7 +105,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
and c.id = #{id,jdbcType=INTEGER}
|
|
|
</if>
|
|
|
<if test="activityName != null" >
|
|
|
- and c.activity_name = #{activityName,jdbcType=VARCHAR}
|
|
|
+ and c.activity_name like CONCAT(CONCAT('%', #{activityName,jdbcType=VARCHAR}), '%');
|
|
|
</if>
|
|
|
<if test="activityType != null" >
|
|
|
and c.activity_type = #{activityType,jdbcType=VARCHAR}
|
|
|
@@ -266,4 +270,58 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
AND t.course_id =#{goodsId}
|
|
|
</if>
|
|
|
</select>
|
|
|
+
|
|
|
+
|
|
|
+ <select id="selectConfiguraCount" parameterType="com.zhongzheng.modules.activity.bo.ActivityConfigurationQueryBo" resultType="long">
|
|
|
+ SELECT
|
|
|
+ count(c.id)
|
|
|
+ FROM
|
|
|
+ activity_configuration c
|
|
|
+ WHERE 1=1
|
|
|
+ <if test="id != null" >
|
|
|
+ and c.id = #{id,jdbcType=INTEGER}
|
|
|
+ </if>
|
|
|
+ <if test="activityName != null" >
|
|
|
+ and c.activity_name like CONCAT(CONCAT('%', #{activityName,jdbcType=VARCHAR}), '%');
|
|
|
+ </if>
|
|
|
+ <if test="activityType != null" >
|
|
|
+ and c.activity_type = #{activityType,jdbcType=VARCHAR}
|
|
|
+ </if>
|
|
|
+ <if test="description != null" >
|
|
|
+ and c.description = #{description,jdbcType=VARCHAR}
|
|
|
+ </if>
|
|
|
+ <if test="startTime != null" >
|
|
|
+ and c.start_time >= #{startTime,jdbcType=INTEGER}
|
|
|
+ </if>
|
|
|
+ <if test="endTime != null" >
|
|
|
+ and c.end_time <= #{endTime,jdbcType=INTEGER}
|
|
|
+ </if>
|
|
|
+ <if test="price != null" >
|
|
|
+ and c.price = #{price,jdbcType=DECIMAL}
|
|
|
+ </if>
|
|
|
+ <if test="quantity != null" >
|
|
|
+ and c.quantity = #{quantity,jdbcType=INTEGER}
|
|
|
+ </if>
|
|
|
+ <if test="liveContent != null" >
|
|
|
+ and c.live_content = #{liveContent,jdbcType=VARCHAR}
|
|
|
+ </if>
|
|
|
+ <if test="liveAdress != null" >
|
|
|
+ and c.live_adress = #{liveAdress,jdbcType=VARCHAR}
|
|
|
+ </if>
|
|
|
+ <if test="createTime != null" >
|
|
|
+ and c.create_time = #{createTime,jdbcType=INTEGER}
|
|
|
+ </if>
|
|
|
+ <if test="updateTime != null" >
|
|
|
+ and c.update_time = #{updateTime,jdbcType=INTEGER}
|
|
|
+ </if>
|
|
|
+ <choose>
|
|
|
+ <when test="status !=null and status != ''">
|
|
|
+ and c.status = #{status}
|
|
|
+ </when>
|
|
|
+ <otherwise>
|
|
|
+ and c.status != 0
|
|
|
+ </otherwise>
|
|
|
+ </choose>
|
|
|
+ order by c.update_time desc
|
|
|
+ </select>
|
|
|
</mapper>
|