|
@@ -548,33 +548,8 @@ public class SceneFileBuildServiceImpl extends ServiceImpl<ISceneFileBuildMapper
|
|
|
return ResultData.ok();
|
|
|
}
|
|
|
|
|
|
+ // 测试环境不予计算V3场景
|
|
|
private ResultData callV3(String preParams, JSONObject fdageJson,String api) {
|
|
|
- String cameraName = fdageJson.getJSONObject("cam").getString("uuid");
|
|
|
-
|
|
|
- Camera camera = cameraService.getByChildName(cameraName);
|
|
|
-
|
|
|
- if (camera == null) {
|
|
|
- throw new BusinessException(CameraConstant.FAILURE_6003);
|
|
|
- }
|
|
|
-
|
|
|
- CameraDetail cameraDetail = cameraDetailService.getByCameraId(camera.getId());
|
|
|
- if (cameraDetail == null) {
|
|
|
- log.error("该相机详情不存在:" + cameraName);
|
|
|
- throw new BusinessException(CameraConstant.FAILURE_6003);
|
|
|
- }
|
|
|
- log.info("相机详情:{}",JSONObject.toJSONString(cameraDetail));
|
|
|
- // 判断是否是正顺的场景,如果是正顺的场景,则发送到原来的系统进行计算
|
|
|
- if (!ObjectUtils.isEmpty(cameraDetail.getCompanyId())) {
|
|
|
- Company company = companyService.getById(cameraDetail.getCompanyId());
|
|
|
- if(ObjectUtils.isEmpty(company)){
|
|
|
- log.error("企业配置有误:" + cameraName);
|
|
|
- throw new BusinessException(CameraConstant.FAILURE_6003);
|
|
|
- }
|
|
|
- if (ObjectUtils.isEmpty(company.getSceneVersion()) && company.getSceneVersion().equals("V3")) {
|
|
|
- callV3Service(preParams,api);
|
|
|
- return ResultData.ok();
|
|
|
- }
|
|
|
- }
|
|
|
return null;
|
|
|
}
|
|
|
|