| | |
| | | private final LedPlayerEntityService ledPlayerEntityService; |
| | | private VnnoxAPIUtil vnnoxAPIUtil; |
| | | private final LEDProgramService ledProgramService; |
| | | private final ClientService clientService; |
| | | |
| | | public boolean addPlan(PlayPlanParam playPlanParam) { |
| | | |
| | | PlayPlanNv playPlan = new PlayPlanNv(); |
| | | if (AdministratorEnums.CUSTOMER.getCode().equals(SecurityUtils.getAdministratorIdentity())) { |
| | | if (SecurityUtils.getClientId()!=null){ |
| | | playPlan.setUserId(SecurityUtils.getUserId()); |
| | | if(clientService.findClientId()){ |
| | | playPlan.setClientId(clientService.getClientId()); |
| | | } |
| | | } |
| | | playPlan.setName(playPlanParam.getName()); |
| | | playPlan.setLedProgramName(playPlanParam.getLedProgramName()); |
| | |
| | | program.setPages(JSON.parseObject(pushToLed.getPages(), List.class)); |
| | | program.setSchedule(JSON.parseObject(pushToLed.getSchedule(), Map.class)); |
| | | program.setNoticeUrl(VnnoxConstant.NOTIFY_URL); |
| | | /* Map schedule = JSON.parseObject(pushToLed.getSchedule(), Map.class); |
| | | Map<String,Object> push=new HashMap<>(); |
| | | push.put("playerIds",playerIds); |
| | | push.put("pages",pages); |
| | | push.put("schedule",schedule); |
| | | push.put("noticeUrl", VnnoxConstant.SCREEN_SHOT_NOTIFY_URL); |
| | | */ |
| | | VnnoxResultResponse vnnoxResultResponse = vnnoxProgramAPIUtil.normalProgram(program); |
| | | VnnoxResult vnnoxResult = vnnoxAPIUtil.volChange(playerIds, Integer.valueOf(one.getVolume()).intValue()); |
| | | |
| | | // VnnoxResultResponse vnnoxResultResponse = vnnoxProgramAPIUtil.normalProgram(push); |
| | | List<String> success = new ArrayList<>(); |
| | | List<String> fail = new ArrayList<>(); |
| | | // List<String> success=new ArrayList<>(); |
| | | // if(vnnoxResultResponse.getData().getSuccess()!=null&&vnnoxResultResponse.getData()!=null){ |
| | | // success = vnnoxResultResponse.getData().getSuccess(); |
| | | // } |
| | | // //success.addAll(vnnoxResult.getSuccess()); |
| | | |
| | | // if(vnnoxResultResponse.getData().getFail()!=null&vnnoxResultResponse.getData()!=null){ |
| | | // fail= vnnoxResultResponse.getData().getFail(); |
| | | // } |
| | | if (vnnoxResultResponse.getData() != null) { |
| | | success = vnnoxResultResponse.getData().getSuccess(); |
| | | fail = vnnoxResultResponse.getData().getFail(); |