|
@@ -0,0 +1,87 @@
|
|
|
+<?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.ruoyi.equity.mapper.SendMessageRecordMapper">
|
|
|
+
|
|
|
+ <resultMap type="SendMessageRecord" id="SendMessageRecordResult">
|
|
|
+ <result property="sendMessageId" column="send_message_id" />
|
|
|
+ <result property="msgType" column="msg_type" />
|
|
|
+ <result property="companyId" column="company_id" />
|
|
|
+ <result property="msgContent" column="msg_content" />
|
|
|
+ <result property="sendTime" column="send_time" />
|
|
|
+ <result property="createBy" column="create_by" />
|
|
|
+ <result property="createTime" column="create_time" />
|
|
|
+ <result property="updateBy" column="update_by" />
|
|
|
+ <result property="updateTime" column="update_time" />
|
|
|
+ <result property="remark" column="remark" />
|
|
|
+ </resultMap>
|
|
|
+
|
|
|
+ <sql id="selectSendMessageRecordVo">
|
|
|
+ select send_message_id, msg_type, company_id, msg_content, send_time, create_by, create_time, update_by, update_time, remark from e_send_message_record
|
|
|
+ </sql>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ <select id="selectSendMessageRecordBySendMessageId" parameterType="Long" resultMap="SendMessageRecordResult">
|
|
|
+ <include refid="selectSendMessageRecordVo"/>
|
|
|
+ where send_message_id = #{sendMessageId}
|
|
|
+ </select>
|
|
|
+ <select id="selectSendMessageRecordList" resultType="com.ruoyi.equity.domain.vo.SendMessageRecordVO">
|
|
|
+ select *,(select shareholder_name from e_shareholder_info esi where esi.shareholder_id = esmr.company_id) as companyName
|
|
|
+ from e_send_message_record esmr
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <insert id="insertSendMessageRecord" parameterType="SendMessageRecord" useGeneratedKeys="true" keyProperty="sendMessageId">
|
|
|
+ insert into e_send_message_record
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="msgType != null and msgType != ''">msg_type,</if>
|
|
|
+ <if test="companyId != null">company_id,</if>
|
|
|
+ <if test="msgContent != null and msgContent != ''">msg_content,</if>
|
|
|
+ <if test="sendTime != null">send_time,</if>
|
|
|
+ <if test="createBy != null">create_by,</if>
|
|
|
+ <if test="createTime != null">create_time,</if>
|
|
|
+ <if test="updateBy != null">update_by,</if>
|
|
|
+ <if test="updateTime != null">update_time,</if>
|
|
|
+ <if test="remark != null">remark,</if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="msgType != null and msgType != ''">#{msgType},</if>
|
|
|
+ <if test="companyId != null">#{companyId},</if>
|
|
|
+ <if test="msgContent != null and msgContent != ''">#{msgContent},</if>
|
|
|
+ <if test="sendTime != null">#{sendTime},</if>
|
|
|
+ <if test="createBy != null">#{createBy},</if>
|
|
|
+ <if test="createTime != null">#{createTime},</if>
|
|
|
+ <if test="updateBy != null">#{updateBy},</if>
|
|
|
+ <if test="updateTime != null">#{updateTime},</if>
|
|
|
+ <if test="remark != null">#{remark},</if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+
|
|
|
+ <update id="updateSendMessageRecord" parameterType="SendMessageRecord">
|
|
|
+ update e_send_message_record
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
+ <if test="msgType != null and msgType != ''">msg_type = #{msgType},</if>
|
|
|
+ <if test="companyId != null">company_id = #{companyId},</if>
|
|
|
+ <if test="msgContent != null and msgContent != ''">msg_content = #{msgContent},</if>
|
|
|
+ <if test="sendTime != null">send_time = #{sendTime},</if>
|
|
|
+ <if test="createBy != null">create_by = #{createBy},</if>
|
|
|
+ <if test="createTime != null">create_time = #{createTime},</if>
|
|
|
+ <if test="updateBy != null">update_by = #{updateBy},</if>
|
|
|
+ <if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
+ <if test="remark != null">remark = #{remark},</if>
|
|
|
+ </trim>
|
|
|
+ where send_message_id = #{sendMessageId}
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <delete id="deleteSendMessageRecordBySendMessageId" parameterType="Long">
|
|
|
+ delete from e_send_message_record where send_message_id = #{sendMessageId}
|
|
|
+ </delete>
|
|
|
+
|
|
|
+ <delete id="deleteSendMessageRecordBySendMessageIds" parameterType="String">
|
|
|
+ delete from e_send_message_record where send_message_id in
|
|
|
+ <foreach item="sendMessageId" collection="array" open="(" separator="," close=")">
|
|
|
+ #{sendMessageId}
|
|
|
+ </foreach>
|
|
|
+ </delete>
|
|
|
+</mapper>
|