|
|
@@ -139,20 +139,23 @@ public class DownService implements IDownService {
|
|
|
}
|
|
|
|
|
|
private void saveLog(ScenePlus scenePlus,Integer sceneVersion,String type,Integer isObj){
|
|
|
- String userName = (String) StpUtil.getExtra("userName");
|
|
|
- String nickName = (String) StpUtil.getExtra("nickName");
|
|
|
- String deptId = tmDepartmentService.getDeptId();
|
|
|
- TmDepartment tmDepartment = tmDepartmentService.getById(deptId);
|
|
|
- Camera camera = cameraService.getByCameraId(scenePlus.getCameraId());
|
|
|
SceneDownLog sceneDownloadLogEntity = new SceneDownLog();
|
|
|
+ if(!"offline".equals(type)){
|
|
|
+ String userName = (String) StpUtil.getExtra("userName");
|
|
|
+ String nickName = (String) StpUtil.getExtra("nickName");
|
|
|
+ String deptId = tmDepartmentService.getDeptId();
|
|
|
+ TmDepartment tmDepartment = tmDepartmentService.getById(deptId);
|
|
|
+ Camera camera = cameraService.getByCameraId(scenePlus.getCameraId());
|
|
|
+ sceneDownloadLogEntity.setUserName(userName);
|
|
|
+ sceneDownloadLogEntity.setNickName(nickName);
|
|
|
+ sceneDownloadLogEntity.setSnCode(camera.getSnCode());
|
|
|
+ sceneDownloadLogEntity.setDeptName(tmDepartment.getName());
|
|
|
+ sceneDownloadLogEntity.setDeptLevel(tmDepartment.getDeptType());
|
|
|
+ sceneDownloadLogEntity.setDeptId(deptId);
|
|
|
+ }
|
|
|
+
|
|
|
sceneDownloadLogEntity.setSceneNum(scenePlus.getNum());
|
|
|
sceneDownloadLogEntity.setSceneTitle(scenePlus.getTitle());
|
|
|
- sceneDownloadLogEntity.setUserName(userName);
|
|
|
- sceneDownloadLogEntity.setNickName(nickName);
|
|
|
- sceneDownloadLogEntity.setSnCode(camera.getSnCode());
|
|
|
- sceneDownloadLogEntity.setDeptName(tmDepartment.getName());
|
|
|
- sceneDownloadLogEntity.setDeptLevel(tmDepartment.getDeptType());
|
|
|
- sceneDownloadLogEntity.setDeptId(deptId);
|
|
|
sceneDownloadLogEntity.setStatus(0);
|
|
|
sceneDownloadLogEntity.setVersion(sceneVersion);
|
|
|
sceneDownloadLogEntity.setIsObj(isObj);
|