|
...
|
...
|
@@ -11,10 +11,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<result property="id" column="id" />
|
|
|
|
<result property="sort" column="sort" />
|
|
|
|
<result property="update_time" column="update_time" />
|
|
|
|
<result property="phone" column="phone" />
|
|
|
|
</resultMap>
|
|
|
|
|
|
|
|
<sql id="selectContentGroupManagementVo">
|
|
|
|
select `content`, `create_time`, `group_name`, `id`, `sort`,`update_time` from content_group_management
|
|
|
|
select `content`, `create_time`, `group_name`, `id`, `sort`,`update_time`,`phone` from content_group_management
|
|
|
|
</sql>
|
|
|
|
|
|
|
|
<select id="selectContentGroupManagementList" parameterType="ContentGroupManagement" resultMap="ContentGroupManagementResult">
|
|
...
|
...
|
@@ -23,6 +24,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="params.beginCreate_time != null and params.beginCreate_time != '' and params.endCreate_time != null and params.endCreate_time != ''"> and create_time between #{params.beginCreate_time} and #{params.endCreate_time}</if>
|
|
|
|
<if test="group_name != null and group_name != ''"> and group_name like concat('%', #{group_name}, '%')</if>
|
|
|
|
<if test="id != null "> and id = #{id}</if>
|
|
|
|
<if test="phone != null and phone != ''">
|
|
|
|
AND phone like concat('%', #{phone}, '%')
|
|
|
|
</if>
|
|
|
|
</where>
|
|
|
|
order by `sort` desc
|
|
|
|
</select>
|
|
...
|
...
|
@@ -39,12 +43,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="create_time != null">create_time,</if>
|
|
|
|
<if test="group_name != null and group_name != ''">group_name,</if>
|
|
|
|
<if test="sort != null">sort,</if>
|
|
|
|
<if test="phone != null">phone,</if>
|
|
|
|
</trim>
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
<if test="content != null and content != ''">#{content},</if>
|
|
|
|
<if test="create_time != null">#{create_time},</if>
|
|
|
|
<if test="group_name != null and group_name != ''">#{group_name},</if>
|
|
|
|
<if test="sort != null">#{sort},</if>
|
|
|
|
<if test="phone != null">#{phone},</if>
|
|
|
|
</trim>
|
|
|
|
</insert>
|
|
|
|
|
|
...
|
...
|
@@ -56,6 +62,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="group_name != null and group_name != ''">group_name = #{group_name},</if>
|
|
|
|
<if test="sort != null">sort = #{sort},</if>
|
|
|
|
<if test="update_time != null">update_time = #{update_time},</if>
|
|
|
|
<if test="phone != null">phone = #{phone},</if>
|
|
|
|
</trim>
|
|
|
|
where id = #{id}
|
|
|
|
</update>
|
...
|
...
|
|