浏览代码

fix: 公司邮箱发送状态查询整改

chenjianhua 7 月之前
父节点
当前提交
67493772f0
共有 1 个文件被更改,包括 8 次插入2 次删除
  1. 8 2
      service-base/src/main/resources/mapper/CompanyEmailHistoryMapper.xml

+ 8 - 2
service-base/src/main/resources/mapper/CompanyEmailHistoryMapper.xml

@@ -55,9 +55,12 @@
         <if test="email != null and email !=''">
         <if test="email != null and email !=''">
             and cec.email like concat('%',#{email},'%')
             and cec.email like concat('%',#{email},'%')
         </if>
         </if>
-        <if test="sendStatus != null">
+        <if test="sendStatus != null and sendStatus != -1">
             and maxce.send_status=#{sendStatus}
             and maxce.send_status=#{sendStatus}
         </if>
         </if>
+        <if test="sendStatus == -1">
+            and maxce.send_status is null
+        </if>
         order by maxce.send_time desc
         order by maxce.send_time desc
         limit #{offset},#{pageSize}
         limit #{offset},#{pageSize}
     </select>
     </select>
@@ -79,9 +82,12 @@
         <if test="email != null and email !=''">
         <if test="email != null and email !=''">
             and cec.email like concat('%',#{email},'%')
             and cec.email like concat('%',#{email},'%')
         </if>
         </if>
-        <if test="sendStatus != null">
+        <if test="sendStatus != null and sendStatus != -1">
             and maxce.send_status=#{sendStatus}
             and maxce.send_status=#{sendStatus}
         </if>
         </if>
+        <if test="sendStatus == -1">
+            and maxce.send_status is null
+        </if>
     </select>
     </select>
 
 
     <select id="searchEmailHistory" resultMap="BaseResultMap">
     <select id="searchEmailHistory" resultMap="BaseResultMap">