修复推流设备更新时国标信息查询错误的BUG

This commit is contained in:
lin
2025-11-07 15:02:13 +08:00
parent 7b4c8881aa
commit 2de8db731c
2 changed files with 6 additions and 2 deletions

View File

@@ -106,7 +106,8 @@ public interface StreamPushMapper {
int getAllPushing(Boolean usePushingAsStatus);
@MapKey("uniqueKey")
@Select("SELECT CONCAT(wsp.app, wsp.stream) as unique_key, wsp.*, wsp.* , wdc.id as gb_id " +
@Select("SELECT CONCAT(wsp.app, wsp.stream) as unique_key, wsp.*, wdc.* , " +
" wdc.id as gb_id " +
" from wvp_stream_push wsp " +
" LEFT join wvp_device_channel wdc on wdc.data_type = 2 and wsp.id = wdc.data_device_id")
Map<String, StreamPush> getAllAppAndStreamMap();

View File

@@ -144,6 +144,9 @@ public class CameraChannelService implements CommandLineRunner {
for (CommonGBChannel channel : channelList) {
if (channel.getGbPtzType() != null && channel.getGbPtzType() == 99) {
CommonGBChannel oldChannel = oldChannelMap.get(channel.getGbDeviceId());
if (channel.getGbStatus() == null) {
channel.setGbStatus(oldChannel.getGbStatus());
}
if (oldChannel != null) {
if (oldChannel.getGbPtzType() != null && oldChannel.getGbPtzType() == 99) {
resultListForUpdate.add(channel);
@@ -251,7 +254,7 @@ public class CameraChannelService implements CommandLineRunner {
jsonObject.put("speed", mobilePosition.getSpeed());
jsonObject.put("topGroupGAlias", cameraChannel.getTopGroupGAlias());
jsonObject.put("groupAlias", cameraChannel.getGroupAlias());
log.info("[redis发送通知] 发送 移动设备位置信息移动位置 {}: {}", REDIS_GPS_MESSAGE, jsonObject.toString());
log.info("[SY-redis发送通知] 发送 移动设备位置信息移动位置 {}: {}", REDIS_GPS_MESSAGE, jsonObject.toString());
redisTemplate.convertAndSend(REDIS_GPS_MESSAGE, jsonObject);
}