| | |
| | | upWarnMsgFileListAck.setInferiorPlatformId(inferiorPlatformId); |
| | | upWarnMsgFileListAck.setCreateTime(LocalDateTime.now().toEpochSecond(ZoneOffset.ofHours(8))); |
| | | upWarnMsgFileListAckDao.save(upWarnMsgFileListAck); |
| | | //修改报警处理结果 |
| | | //修改报警附件数据 |
| | | UPWarnMsgAdptInfo upWarnMsgAdptInfo = upWarnMsgAdptInfoDao.findByInfoIdIs(upWarnMsgFileListAck.getInfoId()); |
| | | if(upWarnMsgFileListAck.getFileList().size() > 0){ |
| | | StringJoiner joiner = new StringJoiner(","); |
| | |
| | | joiner.add(file.getFileUrl()); |
| | | } |
| | | }); |
| | | upWarnMsgAdptInfo.setPicUrl(joiner.length() > 0 ? joiner.toString() : ""); |
| | | upWarnMsgAdptInfo.setPicUrl(joiner.toString()); |
| | | }else{ |
| | | upWarnMsgAdptInfo.setPicUrl("*"); |
| | | } |
| | | upWarnMsgAdptInfoDao.save(upWarnMsgAdptInfo); |
| | | } |
| | |
| | | //海康威视直接走接口 |
| | | if(25439966 == inferiorPlatformId){ |
| | | try { |
| | | if(null == upWarnMsgAdptInfo.getPicUrl()){ |
| | | if(!StringUtils.hasLength(upWarnMsgAdptInfo.getPicUrl())){ |
| | | FindPicturesByAlarmIdRequest findPicturesByAlarmIdRequest = new FindPicturesByAlarmIdRequest(); |
| | | findPicturesByAlarmIdRequest.setAlarmId(upWarnMsgAdptInfo.getInfoId()); |
| | | long warnTime = upWarnMsgAdptInfo.getWarnTime(); |
| | |
| | | String url = jsonObject1.getString("url"); |
| | | joiner.add(url); |
| | | } |
| | | upWarnMsgAdptInfo.setPicUrl(joiner.length() > 0 ? joiner.toString() : ""); |
| | | upWarnMsgAdptInfo.setPicUrl(joiner.length() > 0 ? joiner.toString() : "*"); |
| | | upWarnMsgAdptInfoDao.save(upWarnMsgAdptInfo); |
| | | } |
| | | } |
| | |
| | | upWarnMsgAdptInfo.setPicUrl(joiner.toString()); |
| | | } |
| | | }else{ |
| | | upWarnMsgAdptInfo.setPicUrl(""); |
| | | upWarnMsgAdptInfo.setPicUrl("*"); |
| | | } |
| | | upWarnMsgAdptInfoDao.save(upWarnMsgAdptInfo); |
| | | |