141 lines
8.4 KiB
XML
141 lines
8.4 KiB
XML
|
|
<?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.bonus.system.mapper.BmMeetingPublishMapper">
|
||
|
|
|
||
|
|
<resultMap type="BmMeetingPublish" id="BmMeetingPublishResult">
|
||
|
|
<result property="id" column="id" />
|
||
|
|
<result property="meetingTheme" column="meeting_theme" />
|
||
|
|
<result property="meetingType" column="meeting_type" />
|
||
|
|
<result property="meetingContent" column="meeting_content" />
|
||
|
|
<result property="startTime" column="start_time" />
|
||
|
|
<result property="endTime" column="end_time" />
|
||
|
|
<result property="pictureAddress" column="picture_address" />
|
||
|
|
<result property="unitName" column="unit_name" />
|
||
|
|
<result property="projectName" column="project_name" />
|
||
|
|
<result property="emcee" column="emcee" />
|
||
|
|
<result property="noteTaker" column="note_taker" />
|
||
|
|
<result property="meetintTime" column="meetint_time" />
|
||
|
|
<result property="meetingLocat" column="meeting_locat" />
|
||
|
|
<result property="activityContent" column="activity_content" />
|
||
|
|
<result property="meetingRecord" column="meeting_record" />
|
||
|
|
<result property="createUserId" column="create_user_id" />
|
||
|
|
<result property="createTime" column="create_time" />
|
||
|
|
<result property="updateTime" column="update_time" />
|
||
|
|
<result property="isActive" column="is_active" />
|
||
|
|
</resultMap>
|
||
|
|
|
||
|
|
<sql id="selectBmMeetingPublishVo">
|
||
|
|
select id, meeting_theme, meeting_type, meeting_content, start_time, end_time, picture_address, unit_name, project_name, emcee, note_taker, meetint_time, meeting_locat, activity_content, meeting_record, create_user_id, create_time, update_time, is_active from bm_meeting_publish
|
||
|
|
</sql>
|
||
|
|
|
||
|
|
<select id="selectBmMeetingPublishList" parameterType="BmMeetingPublish" resultMap="BmMeetingPublishResult">
|
||
|
|
<include refid="selectBmMeetingPublishVo"/>
|
||
|
|
<where>
|
||
|
|
<if test="meetingTheme != null and meetingTheme != ''"> and meeting_theme like concat('%', #{meetingTheme}, '%')</if>
|
||
|
|
<if test="meetingType != null and meetingType != ''"> and meeting_type = #{meetingType}</if>
|
||
|
|
<if test="meetingContent != null and meetingContent != ''"> and meeting_content = #{meetingContent}</if>
|
||
|
|
<if test="pictureAddress != null and pictureAddress != ''"> and picture_address = #{pictureAddress}</if>
|
||
|
|
<if test="unitName != null and unitName != ''"> and unit_name like concat('%', #{unitName}, '%')</if>
|
||
|
|
<if test="projectName != null and projectName != ''"> and project_name like concat('%', #{projectName}, '%')</if>
|
||
|
|
<if test="emcee != null and emcee != ''"> and emcee = #{emcee}</if>
|
||
|
|
<if test="noteTaker != null and noteTaker != ''"> and note_taker = #{noteTaker}</if>
|
||
|
|
<if test="meetintTime != null and meetintTime != ''"> and meetint_time = #{meetintTime}</if>
|
||
|
|
<if test="meetingLocat != null and meetingLocat != ''"> and meeting_locat = #{meetingLocat}</if>
|
||
|
|
<if test="activityContent != null and activityContent != ''"> and activity_content = #{activityContent}</if>
|
||
|
|
<if test="meetingRecord != null and meetingRecord != ''"> and meeting_record = #{meetingRecord}</if>
|
||
|
|
<if test="createUserId != null "> and create_user_id = #{createUserId}</if>
|
||
|
|
<if test="isActive != null and isActive != ''"> and is_active = #{isActive}</if>
|
||
|
|
|
||
|
|
<if test="startTime != null and startTime != ''">
|
||
|
|
and start_time BETWEEN #{startTime} AND #{endTime}
|
||
|
|
</if>
|
||
|
|
</where>
|
||
|
|
</select>
|
||
|
|
|
||
|
|
<select id="selectBmMeetingPublishById" parameterType="Long" resultMap="BmMeetingPublishResult">
|
||
|
|
<include refid="selectBmMeetingPublishVo"/>
|
||
|
|
where id = #{id}
|
||
|
|
</select>
|
||
|
|
|
||
|
|
<insert id="insertBmMeetingPublish" parameterType="BmMeetingPublish" useGeneratedKeys="true" keyProperty="id">
|
||
|
|
insert into bm_meeting_publish
|
||
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||
|
|
<if test="meetingTheme != null">meeting_theme,</if>
|
||
|
|
<if test="meetingType != null">meeting_type,</if>
|
||
|
|
<if test="meetingContent != null">meeting_content,</if>
|
||
|
|
<if test="startTime != null">start_time,</if>
|
||
|
|
<if test="endTime != null">end_time,</if>
|
||
|
|
<if test="pictureAddress != null">picture_address,</if>
|
||
|
|
<if test="unitName != null">unit_name,</if>
|
||
|
|
<if test="projectName != null">project_name,</if>
|
||
|
|
<if test="emcee != null">emcee,</if>
|
||
|
|
<if test="noteTaker != null">note_taker,</if>
|
||
|
|
<if test="meetintTime != null">meetint_time,</if>
|
||
|
|
<if test="meetingLocat != null">meeting_locat,</if>
|
||
|
|
<if test="activityContent != null">activity_content,</if>
|
||
|
|
<if test="meetingRecord != null">meeting_record,</if>
|
||
|
|
<if test="createUserId != null">create_user_id,</if>
|
||
|
|
<if test="createTime != null">create_time,</if>
|
||
|
|
<if test="updateTime != null">update_time,</if>
|
||
|
|
<if test="isActive != null">is_active,</if>
|
||
|
|
</trim>
|
||
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||
|
|
<if test="meetingTheme != null">#{meetingTheme},</if>
|
||
|
|
<if test="meetingType != null">#{meetingType},</if>
|
||
|
|
<if test="meetingContent != null">#{meetingContent},</if>
|
||
|
|
<if test="startTime != null">#{startTime},</if>
|
||
|
|
<if test="endTime != null">#{endTime},</if>
|
||
|
|
<if test="pictureAddress != null">#{pictureAddress},</if>
|
||
|
|
<if test="unitName != null">#{unitName},</if>
|
||
|
|
<if test="projectName != null">#{projectName},</if>
|
||
|
|
<if test="emcee != null">#{emcee},</if>
|
||
|
|
<if test="noteTaker != null">#{noteTaker},</if>
|
||
|
|
<if test="meetintTime != null">#{meetintTime},</if>
|
||
|
|
<if test="meetingLocat != null">#{meetingLocat},</if>
|
||
|
|
<if test="activityContent != null">#{activityContent},</if>
|
||
|
|
<if test="meetingRecord != null">#{meetingRecord},</if>
|
||
|
|
<if test="createUserId != null">#{createUserId},</if>
|
||
|
|
<if test="createTime != null">#{createTime},</if>
|
||
|
|
<if test="updateTime != null">#{updateTime},</if>
|
||
|
|
<if test="isActive != null">#{isActive},</if>
|
||
|
|
</trim>
|
||
|
|
</insert>
|
||
|
|
|
||
|
|
<update id="updateBmMeetingPublish" parameterType="BmMeetingPublish">
|
||
|
|
update bm_meeting_publish
|
||
|
|
<trim prefix="SET" suffixOverrides=",">
|
||
|
|
<if test="meetingTheme != null">meeting_theme = #{meetingTheme},</if>
|
||
|
|
<if test="meetingType != null">meeting_type = #{meetingType},</if>
|
||
|
|
<if test="meetingContent != null">meeting_content = #{meetingContent},</if>
|
||
|
|
<if test="startTime != null">start_time = #{startTime},</if>
|
||
|
|
<if test="endTime != null">end_time = #{endTime},</if>
|
||
|
|
<if test="pictureAddress != null">picture_address = #{pictureAddress},</if>
|
||
|
|
<if test="unitName != null">unit_name = #{unitName},</if>
|
||
|
|
<if test="projectName != null">project_name = #{projectName},</if>
|
||
|
|
<if test="emcee != null">emcee = #{emcee},</if>
|
||
|
|
<if test="noteTaker != null">note_taker = #{noteTaker},</if>
|
||
|
|
<if test="meetintTime != null">meetint_time = #{meetintTime},</if>
|
||
|
|
<if test="meetingLocat != null">meeting_locat = #{meetingLocat},</if>
|
||
|
|
<if test="activityContent != null">activity_content = #{activityContent},</if>
|
||
|
|
<if test="meetingRecord != null">meeting_record = #{meetingRecord},</if>
|
||
|
|
<if test="createUserId != null">create_user_id = #{createUserId},</if>
|
||
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||
|
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||
|
|
<if test="isActive != null">is_active = #{isActive},</if>
|
||
|
|
</trim>
|
||
|
|
where id = #{id}
|
||
|
|
</update>
|
||
|
|
|
||
|
|
<delete id="deleteBmMeetingPublishById" parameterType="Long">
|
||
|
|
delete from bm_meeting_publish where id = #{id}
|
||
|
|
</delete>
|
||
|
|
|
||
|
|
<delete id="deleteBmMeetingPublishByIds" parameterType="String">
|
||
|
|
delete from bm_meeting_publish where id in
|
||
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||
|
|
#{id}
|
||
|
|
</foreach>
|
||
|
|
</delete>
|
||
|
|
</mapper>
|