From bb22ca2e9b9c60b0138a322ad49cab7ea8aa06e1 Mon Sep 17 00:00:00 2001
From: ‘liusuyi’ <1951119284@qq.com>
Date: 星期三, 25 十月 2023 17:12:54 +0800
Subject: [PATCH] 修复雷达引导2个相机引导录像重复问题;
---
ard-work/pom.xml | 2 --
ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarFireMapper.xml | 1 +
ard-work/src/main/java/com/ruoyi/alarm/global/service/impl/QueueTaskExecutor.java | 8 +++++++-
ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarPumpMapper.xml | 1 +
4 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/ard-work/pom.xml b/ard-work/pom.xml
index 22d62a1..cb6af83 100644
--- a/ard-work/pom.xml
+++ b/ard-work/pom.xml
@@ -190,6 +190,4 @@
<version>0.5</version>
</dependency>
</dependencies>
-
-
</project>
\ No newline at end of file
diff --git a/ard-work/src/main/java/com/ruoyi/alarm/global/service/impl/QueueTaskExecutor.java b/ard-work/src/main/java/com/ruoyi/alarm/global/service/impl/QueueTaskExecutor.java
index dfce1a1..fd48181 100644
--- a/ard-work/src/main/java/com/ruoyi/alarm/global/service/impl/QueueTaskExecutor.java
+++ b/ard-work/src/main/java/com/ruoyi/alarm/global/service/impl/QueueTaskExecutor.java
@@ -57,7 +57,12 @@
cmd.setOperator(guideTask.getAlarmType());
cmd.setExpired(30);
cmd.setRecordBucketName("record");
- cmd.setRecordObjectName("alarm_" + guideTask.getAlarmId());
+ if (guideTask.getRecordSn().equals(1)) {
+ cmd.setRecordObjectName("alarm_" + guideTask.getAlarmId() + "_1");
+ } else {
+ cmd.setRecordObjectName("alarm_" + guideTask.getAlarmId() + "_2");
+ }
+
log.debug("寮�濮嬪紩瀵�");
boolean guideRes = cameraSdkService.guideTargetPosition(cmd);
if (guideRes) {
@@ -97,6 +102,7 @@
ardAlarmRadarFire.setRecordUrl2(url);
}
ardAlarmRadarFireService.updateArdAlarmRadarFire(ardAlarmRadarFire);
+ break;
case "sys_radar_pump":
ArdAlarmRadarPump ardAlarmRadarPump = new ArdAlarmRadarPump();
ardAlarmRadarPump.setId(guideTask.getAlarmId());
diff --git a/ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarFireMapper.xml b/ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarFireMapper.xml
index e349f24..95ade6e 100644
--- a/ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarFireMapper.xml
+++ b/ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarFireMapper.xml
@@ -102,6 +102,7 @@
<if test="longitude != null">longitude = #{longitude},</if>
<if test="latitude != null">latitude = #{latitude},</if>
<if test="recordUrl1 != null">record_url1 = #{recordUrl1},</if>
+ <if test="recordUrl2 != null">record_url2 = #{recordUrl2},</if>
<if test="viewTime != null">view_time = #{viewTime},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
diff --git a/ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarPumpMapper.xml b/ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarPumpMapper.xml
index a11bd19..d453275 100644
--- a/ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarPumpMapper.xml
+++ b/ard-work/src/main/resources/mapper/alarm/ArdAlarmRadarPumpMapper.xml
@@ -102,6 +102,7 @@
<if test="longitude != null">longitude = #{longitude},</if>
<if test="latitude != null">latitude = #{latitude},</if>
<if test="recordUrl1 != null">record_url1 = #{recordUrl1},</if>
+ <if test="recordUrl2 != null">record_url2 = #{recordUrl2},</if>
<if test="viewTime != null">view_time = #{viewTime},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
--
Gitblit v1.9.3