From 2b29a4a26019e3d1692c4b4c76746dba9fac7b22 Mon Sep 17 00:00:00 2001
From: aijinhui <aijinhui>
Date: 星期六, 07 十月 2023 14:39:16 +0800
Subject: [PATCH] 报警数量统计年
---
ard-work/src/main/resources/mapper/alarm/ArdAlarmCameraMapper.xml | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/ard-work/src/main/resources/mapper/alarm/ArdAlarmCameraMapper.xml b/ard-work/src/main/resources/mapper/alarm/ArdAlarmCameraMapper.xml
index 5beed74..2f919b5 100644
--- a/ard-work/src/main/resources/mapper/alarm/ArdAlarmCameraMapper.xml
+++ b/ard-work/src/main/resources/mapper/alarm/ArdAlarmCameraMapper.xml
@@ -2,7 +2,7 @@
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="com.ruoyi.alarm.cameraAlarm.mapper.ArdAlarmCameraMapper">
+<mapper namespace="com.ruoyi.alarm.camera.mapper.ArdAlarmCameraMapper">
<resultMap type="ArdAlarmCamera" id="ArdAlarmCameraResult">
<result property="id" column="id" />
@@ -166,4 +166,10 @@
and alarm_time<=#{alarmTime}
and view_time is null
</update>
+
+ <select id="cameraYear" resultType="com.ruoyi.statistical.vo.CountVo">
+ select to_char(alarm_time::DATE, 'MM') as month,count(id)
+ from ard_alarm_camera
+ where alarm_time >= #{start} and alarm_time <= #{end} group by month order by month
+ </select>
</mapper>
\ No newline at end of file
--
Gitblit v1.9.3