Browse Source

#实时画面&视频配置查询接口修改

zhongwei
yang_shj 3 months ago
parent
commit
9a42354bca
  1. 9
      hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/controller/StationFrameRecordController.java
  2. 9
      hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/controller/StationVideoRecordController.java

9
hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/controller/StationFrameRecordController.java

@ -11,6 +11,7 @@ import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springblade.core.boot.ctrl.BladeController; import org.springblade.core.boot.ctrl.BladeController;
import org.springblade.core.tool.api.R; import org.springblade.core.tool.api.R;
import org.springblade.core.tool.utils.ObjectUtil;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import javax.validation.Valid; import javax.validation.Valid;
@ -39,10 +40,14 @@ public class StationFrameRecordController extends BladeController {
@ApiOperation(value = "查询站点视频播放保存记录", notes = "传入VideoRecordEntity") @ApiOperation(value = "查询站点视频播放保存记录", notes = "传入VideoRecordEntity")
public R query(@RequestParam("stationId") String stationId, public R query(@RequestParam("stationId") String stationId,
@RequestParam("userId") String userId) { @RequestParam("userId") String userId) {
return R.data(frameRecordService.getOne(Wrappers.<FrameRecordEntity>lambdaQuery() FrameRecordEntity frameRecord = frameRecordService.getOne(Wrappers.<FrameRecordEntity>lambdaQuery()
.eq(FrameRecordEntity::getStationId,stationId) .eq(FrameRecordEntity::getStationId,stationId)
.eq(FrameRecordEntity::getCreateUser,userId) .eq(FrameRecordEntity::getCreateUser,userId)
)); );
if(ObjectUtil.isEmpty(frameRecord)){
return R.status(true);
}
return R.data(frameRecord);
} }

9
hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/controller/StationVideoRecordController.java

@ -9,6 +9,7 @@ import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springblade.core.boot.ctrl.BladeController; import org.springblade.core.boot.ctrl.BladeController;
import org.springblade.core.tool.api.R; import org.springblade.core.tool.api.R;
import org.springblade.core.tool.utils.ObjectUtil;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import javax.validation.Valid; import javax.validation.Valid;
@ -37,10 +38,14 @@ public class StationVideoRecordController extends BladeController {
@ApiOperation(value = "查询站点视频播放保存记录", notes = "传入VideoRecordEntity") @ApiOperation(value = "查询站点视频播放保存记录", notes = "传入VideoRecordEntity")
public R query(@RequestParam("stationId") String stationId, public R query(@RequestParam("stationId") String stationId,
@RequestParam("userId") String userId) { @RequestParam("userId") String userId) {
return R.data(videoRecordService.getOne(Wrappers.<VideoRecordEntity>lambdaQuery() VideoRecordEntity videoRecord = videoRecordService.getOne(Wrappers.<VideoRecordEntity>lambdaQuery()
.eq(VideoRecordEntity::getStationId,stationId) .eq(VideoRecordEntity::getStationId,stationId)
.eq(VideoRecordEntity::getCreateUser,userId) .eq(VideoRecordEntity::getCreateUser,userId)
)); );
if(ObjectUtil.isEmpty(videoRecord)){
return R.status(true);
}
return R.data(videoRecord);
} }

Loading…
Cancel
Save