Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

控制挂载的时候,报The device does not have payload control authority. #27

Open
answerThe opened this issue Jun 15, 2023 · 0 comments

Comments

@answerThe
Copy link

控制挂载的时候,报The device does not have payload control authority. 调试看是设备osd 上报数据 里面的payloadsList 为null.导致检测控制权限判断为空直接报没有控制权限。payloadsList 这个需要怎么用才能上报。挂载直播着,payloadsList 为啥为null public Boolean checkAuthorityPayload(String deviceSn, String payloadIndex) {
return deviceRedisService.getDeviceOnline(deviceSn).flatMap(device ->
Optional.of(DeviceDomainEnum.SUB_DEVICE.getVal() == device.getDomain()
&& !CollectionUtils.isEmpty(device.getPayloadsList())
&& ControlSourceEnum.A.getControlSource()
.equals(device.getPayloadsList().stream()
.filter(payload -> payloadIndex.equals(payload.getPayloadIndex()))
.map(DevicePayloadDTO::getControlSource).findAny()
.orElse(ControlSourceEnum.B.getControlSource())))).orElse(true);

} 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant