| | |
| | | */ |
| | | public Map<String, Object> screenStatusChange(List<LedPlayerEntity> playerList, Integer screenStatus) { |
| | | playerList.forEach(item -> { |
| | | if (item.getPlayerId().isEmpty() || item.getPlayerName().isEmpty() || item.getPlayerName() == null || item.getPlayerId() == null) { |
| | | if (item.getName() == null || item.getPlayerId() == null) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty()) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | }); |
| | |
| | | playerList.forEach(n -> { |
| | | if (finalSuccess.contains(n.getPlayerId())) { |
| | | NovaPushResultVO vo = new NovaPushResultVO(); |
| | | vo.setName(n.getPlayerName()); |
| | | vo.setName(n.getName()); |
| | | vo.setPlayerId(n.getPlayerId()); |
| | | successList.add(vo); |
| | | } else if (finalFail.contains(n.getPlayerId())) { |
| | | NovaPushResultVO vo = new NovaPushResultVO(); |
| | | vo.setName(n.getPlayerName()); |
| | | vo.setName(n.getName()); |
| | | vo.setPlayerId(n.getPlayerId()); |
| | | faileList.add(vo); |
| | | } |
| | |
| | | |
| | | public Map<String, Object> volChange(List<LedPlayerEntity> playerList, Integer vol) { |
| | | playerList.forEach(item -> { |
| | | if (item.getPlayerId().isEmpty() || item.getPlayerName().isEmpty() || item.getPlayerName() == null || item.getPlayerId() == null) { |
| | | if (item.getName() == null || item.getPlayerId() == null) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty()) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | }); |
| | |
| | | playerList.forEach(n -> { |
| | | if (finalSuccess.contains(n.getPlayerId())) { |
| | | NovaPushResultVO vo = new NovaPushResultVO(); |
| | | vo.setName(n.getPlayerName()); |
| | | vo.setName(n.getName()); |
| | | vo.setPlayerId(n.getPlayerId()); |
| | | successList.add(vo); |
| | | } else if (finalFail.contains(n.getPlayerId())) { |
| | | NovaPushResultVO vo = new NovaPushResultVO(); |
| | | vo.setName(n.getPlayerName()); |
| | | vo.setName(n.getName()); |
| | | vo.setPlayerId(n.getPlayerId()); |
| | | faileList.add(vo); |
| | | } |
| | |
| | | |
| | | public Map<String, Object> brightnessChange(List<LedPlayerEntity> playerList, Integer brightness) { |
| | | playerList.forEach(item -> { |
| | | if (item.getPlayerId().isEmpty() || item.getPlayerName().isEmpty() || item.getPlayerName() == null || item.getPlayerId() == null) { |
| | | if (item.getName() == null || item.getPlayerId() == null) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty()) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | }); |
| | |
| | | playerList.forEach(n -> { |
| | | if (finalSuccess.contains(n.getPlayerId())) { |
| | | NovaPushResultVO vo = new NovaPushResultVO(); |
| | | vo.setName(n.getPlayerName()); |
| | | vo.setName(n.getName()); |
| | | vo.setPlayerId(n.getPlayerId()); |
| | | successList.add(vo); |
| | | } else if (finalFail.contains(n.getPlayerId())) { |
| | | NovaPushResultVO vo = new NovaPushResultVO(); |
| | | vo.setName(n.getPlayerName()); |
| | | vo.setName(n.getName()); |
| | | vo.setPlayerId(n.getPlayerId()); |
| | | faileList.add(vo); |
| | | } |
| | |
| | | public Map<String, Object> reboot(List<NovaPushResultVO> nova) { |
| | | List<String> playerIds = new ArrayList<>(); |
| | | nova.forEach(item -> { |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty() || item.getName() == null || item.getPlayerId() == null) { |
| | | if (item.getName() == null || item.getPlayerId() == null) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty()) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | playerIds.add(item.getPlayerId()); |
| | |
| | | public Map<String, Object> syncPlay(List<NovaPushResultVO> nova, Integer option) { |
| | | List<String> playerIds = new ArrayList<>(); |
| | | nova.forEach(item -> { |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty() || item.getName() == null || item.getPlayerId() == null) { |
| | | if (item.getName() == null || item.getPlayerId() == null) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty()) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | playerIds.add(item.getPlayerId()); |
| | |
| | | public Map<String, Object> ntpSync(List<NovaPushResultVO> nova, boolean enable) { |
| | | List<String> playerIds = new ArrayList<>(); |
| | | nova.forEach(item -> { |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty() || item.getName() == null || item.getPlayerId() == null) { |
| | | if (item.getName() == null || item.getPlayerId() == null) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | if (item.getPlayerId().isEmpty() || item.getName().isEmpty()) { |
| | | throw new BusinessException("playerId或playerName为空"); |
| | | } |
| | | playerIds.add(item.getPlayerId()); |