| | |
| | | import com.iailab.framework.web.core.util.WebFrameworkUtils; |
| | | import com.iailab.module.data.mq.consumer.ImageMessage; |
| | | import com.iailab.module.data.video.controller.admin.camera.vo.CameraPageReqVO; |
| | | import com.iailab.module.data.video.dahua.DHConfiguration; |
| | | import com.iailab.module.data.video.dahua.DHSavePath; |
| | | import com.iailab.module.data.video.dao.CameraDao; |
| | | import com.iailab.module.data.video.dao.ImageDao; |
| | |
| | | CameraDTO devCamera = getByCode(params.get("cmdSerial")); |
| | | String strFileName = params.get("strFileName"); |
| | | String imagePath = strFileName.replace("\\", "/"); |
| | | String imageUrl = imagePath.replace(DHSavePath.capturePath, ""); |
| | | String imageUrl = imagePath.replace(DHConfiguration.staticCapturePath, ""); |
| | | ImageEntity image = new ImageEntity(); |
| | | image.setCameraId(devCamera.getId()); |
| | | image.setImagePath(imagePath); |
| | |
| | | imageMessage.setCreateTime(createTime); |
| | | imageMessage.setImageDTO(BeanUtils.toBean(image, ImageDTO.class)); |
| | | rabbitTemplate.convertAndSend(ImageMessage.EXCHANGE, ImageMessage.DAHUA_ROUTING_KEY, imageMessage); |
| | | rabbitTemplate.convertAndSend(ImageMessage.EXCHANGE, ImageMessage.HIKVISION_ROUTING_KEY, imageMessage); |
| | | } |
| | | |
| | | } |