[集群] 增加语音对讲支持

This commit is contained in:
648540858
2025-01-21 17:35:21 +08:00
parent 135f3054e6
commit ba27819874
8 changed files with 117 additions and 15 deletions

View File

@@ -208,16 +208,8 @@ public class PlayController {
if (log.isDebugEnabled()) {
log.debug("语音广播API调用");
}
Device device = deviceService.getDeviceByDeviceId(deviceId);
if (device == null) {
throw new ControllerException(ErrorCode.ERROR400.getCode(), "未找到设备: " + deviceId);
}
DeviceChannel channel = deviceChannelService.getOne(deviceId, channelId);
if (channel == null) {
throw new ControllerException(ErrorCode.ERROR400.getCode(), "未找到通道: " + channelId);
}
return playService.audioBroadcast(device, channel, broadcastMode);
return playService.audioBroadcast(deviceId, channelId, broadcastMode);
}