zhongrj
2023-06-30 abc0ebc7c75a523f9804894e8f46490243aa3e3b
skjcmanager/skjcmanager-service/skjcmanager-alerts/src/main/java/cn/gistack/alerts/sms/mapper/SmsResultMapper.xml
@@ -4,7 +4,16 @@
    <!--自定义分页列表查询-->
    <select id="selectSmsResultPage" resultType="cn.gistack.alerts.sms.vo.SmsResultVO">
        select * from sm_sms_result where 1=1 and is_deleted = 0
        select ssr.*,sst.content templateContent
        from sm_sms_result ssr
        left join sm_sms_template sst on sst.template_id = ssr.template_id and sst.is_deleted = 0
        where 1=1 and ssr.is_deleted = 0
        <if test="smsResult.templateId!=null and smsResult.templateId!=''">
            and ssr.template_id = #{smsResult.templateId}
        </if>
        <if test="smsResult.templateContent!=null and smsResult.templateContent!=''">
            and sst.content like concat('%',#{smsResult.templateContent},'%')
        </if>
        order by id desc
    </select>