|
@@ -242,7 +242,7 @@ public class AppSceneService {
|
|
}
|
|
}
|
|
|
|
|
|
public void deleteForCameraName(Long cameraId, String sceneNum) {
|
|
public void deleteForCameraName(Long cameraId, String sceneNum) {
|
|
- if(cameraId == null || StringUtils.isEmpty(sceneNum)){
|
|
|
|
|
|
+ if( StringUtils.isEmpty(sceneNum)){
|
|
throw new BusinessException(LoginConstant.FAILURE_CODE_3001,LoginConstant.FAILURE_MSG_3001);
|
|
throw new BusinessException(LoginConstant.FAILURE_CODE_3001,LoginConstant.FAILURE_MSG_3001);
|
|
}
|
|
}
|
|
ScenePro scenePro = sceneProService.getByNum(sceneNum);
|
|
ScenePro scenePro = sceneProService.getByNum(sceneNum);
|
|
@@ -256,10 +256,10 @@ public class AppSceneService {
|
|
if(scenePlus != null && scenePlus.getSceneStatus() == 0){
|
|
if(scenePlus != null && scenePlus.getSceneStatus() == 0){
|
|
throw new BusinessException(SceneConstant.FAILURE_CODE_5037, SceneConstant.FAILURE_MSG_5037);
|
|
throw new BusinessException(SceneConstant.FAILURE_CODE_5037, SceneConstant.FAILURE_MSG_5037);
|
|
}
|
|
}
|
|
- if(scenePro!=null && !scenePro.getCameraId().equals(cameraId)){
|
|
|
|
|
|
+ if(cameraId != null && scenePro!=null && !scenePro.getCameraId().equals(cameraId)){
|
|
throw new BusinessException(SceneConstant.FAILURE_CODE_5010, SceneConstant.FAILURE_MSG_5010);
|
|
throw new BusinessException(SceneConstant.FAILURE_CODE_5010, SceneConstant.FAILURE_MSG_5010);
|
|
}
|
|
}
|
|
- if(scenePlus!=null && !scenePlus.getCameraId().equals(cameraId)){
|
|
|
|
|
|
+ if(cameraId != null && scenePlus!=null && !scenePlus.getCameraId().equals(cameraId)){
|
|
throw new BusinessException(SceneConstant.FAILURE_CODE_5010, SceneConstant.FAILURE_MSG_5010);
|
|
throw new BusinessException(SceneConstant.FAILURE_CODE_5010, SceneConstant.FAILURE_MSG_5010);
|
|
}
|
|
}
|
|
Integer sceneSource = null;
|
|
Integer sceneSource = null;
|