| | |
| | | package com.genersoft.iot.vmp.vmanager.gb28181.gbStream; |
| | | |
| | | import com.genersoft.iot.vmp.conf.exception.ControllerException; |
| | | import com.genersoft.iot.vmp.gb28181.bean.GbStream; |
| | | import com.genersoft.iot.vmp.gb28181.bean.ParentPlatform; |
| | | import com.genersoft.iot.vmp.service.IGbStreamService; |
| | | import com.genersoft.iot.vmp.service.IPlatformService; |
| | | import com.genersoft.iot.vmp.storager.IVideoManagerStorage; |
| | | import com.genersoft.iot.vmp.vmanager.bean.ErrorCode; |
| | | import com.genersoft.iot.vmp.vmanager.gb28181.gbStream.bean.GbStreamParam; |
| | | import com.github.pagehelper.PageInfo; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | |
| | | import org.springframework.util.ObjectUtils; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | |
| | | @Tag(name = "视频流关联到级联平台") |
| | |
| | | private IGbStreamService gbStreamService; |
| | | |
| | | @Autowired |
| | | private IVideoManagerStorage storager; |
| | | private IPlatformService platformService; |
| | | |
| | | |
| | | /** |
| | |
| | | gbStreamService.addPlatformInfo(gbStreamParam.getGbStreams(), gbStreamParam.getPlatformId(), gbStreamParam.getCatalogId()); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 保存国标关联 |
| | | * @param gbId |
| | | * @return |
| | | */ |
| | | @Operation(summary = "保存国标关联") |
| | | @GetMapping(value = "/addWithGbid") |
| | | @ResponseBody |
| | | public void add(String gbId, String platformGbId, @RequestParam(required = false) String catalogGbId){ |
| | | List<GbStream> gbStreams = gbStreamService.getGbChannelWithGbid(gbId); |
| | | if (gbStreams.isEmpty()) { |
| | | throw new ControllerException(ErrorCode.ERROR100.getCode(), "gbId的信息未找到"); |
| | | } |
| | | gbStreamService.addPlatformInfo(gbStreams, platformGbId, catalogGbId); |
| | | } |
| | | } |