From 356331d8401267aa7aeb409d1314537aa25ac5ad Mon Sep 17 00:00:00 2001 From: zhubaomin <zhubaomin> Date: 星期二, 25 二月 2025 14:33:03 +0800 Subject: [PATCH] 解决控制器报警与状态SQL语句的错误 --- pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmAlarmStateHistoryMapper.xml | 16 ++++++++-------- 1 files changed, 8 insertions(+), 8 deletions(-) diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmAlarmStateHistoryMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmAlarmStateHistoryMapper.xml index 5fc59a3..5604c9a 100644 --- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmAlarmStateHistoryMapper.xml +++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmAlarmStateHistoryMapper.xml @@ -402,11 +402,11 @@ <if test="intakeName != null and intakeName != '' "> and pint.name like CONCAT('%',#{intakeName,jdbcType=VARCHAR},'%') </if> - <if test="startDt != null"> - and rash.dt >= #{startDt,jdbcType=TIMESTAMP} + <if test="startDt != null and startDt != ''"> + and rasl.dt >= #{startDt,jdbcType=TIMESTAMP} </if> - <if test="endDt != null"> - and rash.dt <= #{endDt,jdbcType=TIMESTAMP} + <if test="endDt != null and endDt != ''"> + and rasl.dt <= #{endDt,jdbcType=TIMESTAMP} </if> </where> </select> @@ -486,11 +486,11 @@ <if test="intakeName != null and intakeName != '' "> and pint.name like CONCAT('%',#{intakeName,jdbcType=VARCHAR},'%') </if> - <if test="startDt != null"> - and rash.dt >= #{startDt,jdbcType=TIMESTAMP} + <if test="startDt != null and startDt != ''"> + and rasl.dt >= #{startDt,jdbcType=TIMESTAMP} </if> - <if test="endDt != null"> - and rash.dt <= #{endDt,jdbcType=TIMESTAMP} + <if test="endDt != null and endDt != ''"> + and rasl.dt <= #{endDt,jdbcType=TIMESTAMP} </if> </where> ORDER BY rash.id DESC -- Gitblit v1.8.0