Showing
1 changed file
with
3 additions
and
0 deletions
... | ... | @@ -65,6 +65,9 @@ public class TkVideoControlServiceImpl implements TkVideoControlService { |
65 | 65 | String tenantId = currentUser.getCurrentTenantId(); |
66 | 66 | // 判断设备、通道是否存在 |
67 | 67 | DeviceDTO deviceDTO = tkDeviceService.checkDeviceByTenantIdAndId(tenantId, deviceId, true); |
68 | + if (null == deviceDTO || !DeviceState.ONLINE.equals(deviceDTO.getDeviceState())) { | |
69 | + throw new TkDataValidationException(ErrorMessage.DEVICE_NOT_ONLINE.getMessage()); | |
70 | + } | |
68 | 71 | SipDeviceDTO sipDeviceDTO = |
69 | 72 | JacksonUtil.convertValue( |
70 | 73 | deviceDTO.getDeviceInfo().get(FastIotConstants.DeviceAdditional.SIP), | ... | ... |