diff --git a/src/main/java/com/genersoft/iot/vmp/service/impl/DeviceServiceImpl.java b/src/main/java/com/genersoft/iot/vmp/service/impl/DeviceServiceImpl.java index bd212ad7e..46f1e9d53 100755 --- a/src/main/java/com/genersoft/iot/vmp/service/impl/DeviceServiceImpl.java +++ b/src/main/java/com/genersoft/iot/vmp/service/impl/DeviceServiceImpl.java @@ -508,6 +508,7 @@ public class DeviceServiceImpl implements IDeviceService { } deviceChannelMapper.clearPlay(device.getDeviceId()); inviteStreamService.clearInviteInfo(device.getDeviceId()); + deviceInStore.setSwitchPrimarySubStream(device.isSwitchPrimarySubStream()); } if (!ObjectUtils.isEmpty(device.getName())) { @@ -597,6 +598,7 @@ public class DeviceServiceImpl implements IDeviceService { } deviceChannelMapper.cleanChannelsByDeviceId(deviceId); deviceMapper.del(deviceId); + redisCatchStorage.removeDevice(deviceId); return true; } diff --git a/src/main/java/com/genersoft/iot/vmp/vmanager/channel/CommonChannelPlatformController.java b/src/main/java/com/genersoft/iot/vmp/vmanager/channel/CommonChannelPlatformController.java index 097b1152f..a9ece055a 100755 --- a/src/main/java/com/genersoft/iot/vmp/vmanager/channel/CommonChannelPlatformController.java +++ b/src/main/java/com/genersoft/iot/vmp/vmanager/channel/CommonChannelPlatformController.java @@ -3,6 +3,7 @@ package com.genersoft.iot.vmp.vmanager.channel; import com.genersoft.iot.vmp.common.CommonGbChannel; import com.genersoft.iot.vmp.conf.UserSetting; import com.genersoft.iot.vmp.conf.exception.ControllerException; +import com.genersoft.iot.vmp.conf.security.JwtUtils; import com.genersoft.iot.vmp.gb28181.bean.ParentPlatform; import com.genersoft.iot.vmp.gb28181.transmit.callback.DeferredResultHolder; import com.genersoft.iot.vmp.service.ICommonGbChannelService; @@ -17,6 +18,7 @@ import com.github.pagehelper.PageInfo; import com.google.common.collect.Lists; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.Parameter; +import io.swagger.v3.oas.annotations.security.SecurityRequirement; import io.swagger.v3.oas.annotations.tags.Tag; import org.apache.commons.lang3.ObjectUtils; import org.slf4j.Logger; @@ -56,7 +58,7 @@ public class CommonChannelPlatformController { /** * 向上级平台添加国标通道 */ - @Operation(summary = "向上级平台添加国标通道") + @Operation(summary = "向上级平台添加国标通道", security = @SecurityRequirement(name = JwtUtils.HEADER)) @PostMapping("/add") @ResponseBody public void addChannelForGB(@RequestBody UpdateChannelParam param) { @@ -85,7 +87,7 @@ public class CommonChannelPlatformController { * @param param 通道关联参数 * @return */ - @Operation(summary = "从上级平台移除国标通道") + @Operation(summary = "从上级平台移除国标通道", security = @SecurityRequirement(name = JwtUtils.HEADER)) @DeleteMapping("/delete") @ResponseBody public void delChannelForGB(@RequestBody UpdateChannelParam param) { diff --git a/src/main/java/com/genersoft/iot/vmp/vmanager/group/GroupController.java b/src/main/java/com/genersoft/iot/vmp/vmanager/group/GroupController.java index da171fbb6..67c6bf661 100644 --- a/src/main/java/com/genersoft/iot/vmp/vmanager/group/GroupController.java +++ b/src/main/java/com/genersoft/iot/vmp/vmanager/group/GroupController.java @@ -1,12 +1,14 @@ package com.genersoft.iot.vmp.vmanager.group; import com.genersoft.iot.vmp.conf.exception.ControllerException; +import com.genersoft.iot.vmp.conf.security.JwtUtils; import com.genersoft.iot.vmp.service.IGroupService; import com.genersoft.iot.vmp.service.bean.Group; import com.genersoft.iot.vmp.vmanager.bean.ErrorCode; import com.github.pagehelper.PageInfo; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.Parameter; +import io.swagger.v3.oas.annotations.security.SecurityRequirement; import io.swagger.v3.oas.annotations.tags.Tag; import org.apache.commons.lang3.ObjectUtils; import org.slf4j.Logger; @@ -26,7 +28,7 @@ public class GroupController { @Autowired private IGroupService groupService; - @Operation(summary = "添加区域") + @Operation(summary = "添加区域", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "group", description = "Group", required = true) @ResponseBody @PostMapping("/add") @@ -34,7 +36,7 @@ public class GroupController { groupService.add(group); } - @Operation(summary = "查询区域") + @Operation(summary = "查询区域", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "query", description = "查询内容", required = true) @Parameter(name = "page", description = "当前页", required = true) @Parameter(name = "count", description = "每页查询数量", required = true) @@ -48,7 +50,7 @@ public class GroupController { return groupService.queryGroup(query, page, count); } - @Operation(summary = "更新区域") + @Operation(summary = "更新区域", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "group", description = "Group", required = true) @ResponseBody @PostMapping("/update") @@ -56,7 +58,7 @@ public class GroupController { groupService.update(group); } - @Operation(summary = "删除区域") + @Operation(summary = "删除区域", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "groupDeviceId", description = "待删除的节点编号", required = true) @ResponseBody @GetMapping("/delete") @@ -68,7 +70,7 @@ public class GroupController { } } - @Operation(summary = "查询区域的子节点") + @Operation(summary = "查询区域的子节点", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "groupParentId", description = "待查询的节点", required = true) @Parameter(name = "page", description = "当前页", required = true) @Parameter(name = "count", description = "每页查询数量", required = true) diff --git a/src/main/java/com/genersoft/iot/vmp/vmanager/region/RegionController.java b/src/main/java/com/genersoft/iot/vmp/vmanager/region/RegionController.java index c3d3105fd..909891f7c 100644 --- a/src/main/java/com/genersoft/iot/vmp/vmanager/region/RegionController.java +++ b/src/main/java/com/genersoft/iot/vmp/vmanager/region/RegionController.java @@ -1,6 +1,7 @@ package com.genersoft.iot.vmp.vmanager.region; import com.genersoft.iot.vmp.conf.exception.ControllerException; +import com.genersoft.iot.vmp.conf.security.JwtUtils; import com.genersoft.iot.vmp.gb28181.bean.Gb28181CodeType; import com.genersoft.iot.vmp.service.IRegionService; import com.genersoft.iot.vmp.service.bean.Region; @@ -8,6 +9,7 @@ import com.genersoft.iot.vmp.vmanager.bean.ErrorCode; import com.github.pagehelper.PageInfo; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.Parameter; +import io.swagger.v3.oas.annotations.security.SecurityRequirement; import io.swagger.v3.oas.annotations.tags.Tag; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -27,7 +29,7 @@ public class RegionController { @Autowired private IRegionService regionService; - @Operation(summary = "添加区域") + @Operation(summary = "添加区域",security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "region", description = "Region", required = true) @ResponseBody @PostMapping("/add") @@ -35,7 +37,7 @@ public class RegionController { regionService.add(region); } - @Operation(summary = "查询区域") + @Operation(summary = "查询区域", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "query", description = "要搜索的内容", required = true) @Parameter(name = "page", description = "当前页", required = true) @Parameter(name = "count", description = "每页查询数量", required = true) @@ -49,7 +51,7 @@ public class RegionController { return regionService.query(query, page, count); } - @Operation(summary = "更新区域") + @Operation(summary = "更新区域" , security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "region", description = "Region", required = true) @ResponseBody @PostMapping("/update") @@ -57,7 +59,7 @@ public class RegionController { regionService.update(region); } - @Operation(summary = "删除区域") + @Operation(summary = "删除区域" , security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "regionDeviceId", description = "区域编码", required = true) @ResponseBody @GetMapping("/delete") @@ -69,7 +71,7 @@ public class RegionController { } } - @Operation(summary = "分页区域子节点") + @Operation(summary = "分页区域子节点", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "regionParentId", description = "行政区划父节点编号", required = true) @Parameter(name = "page", description = "当前页", required = true) @Parameter(name = "count", description = "每页查询数量", required = true) @@ -86,7 +88,7 @@ public class RegionController { return regionService.queryChildRegionList(regionParentId, page, count); } - @Operation(summary = "根据区域Id查询区域") + @Operation(summary = "根据区域Id查询区域", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "regionDeviceId", description = "行政区划节点编号", required = true) @ResponseBody @GetMapping("/one") @@ -99,7 +101,7 @@ public class RegionController { return regionService.queryRegionByDeviceId(regionDeviceId); } - @Operation(summary = "获取所属的行政区划下的行政区划") + @Operation(summary = "获取所属的行政区划下的行政区划", security = @SecurityRequirement(name = JwtUtils.HEADER)) @Parameter(name = "parent", description = "所属的行政区划", required = false) @ResponseBody @GetMapping("/base/child/list") diff --git a/web_src/src/components/GBRecordDetail.vue b/web_src/src/components/GBRecordDetail.vue index 37ec377f5..b800e0c1a 100755 --- a/web_src/src/components/GBRecordDetail.vue +++ b/web_src/src/components/GBRecordDetail.vue @@ -36,7 +36,6 @@ :error="videoError" :message="videoError" :hasAudio="hasAudio" - style="max-height: 100%" fluent autoplay live >
@@ -137,8 +136,11 @@ margin: "10px auto 10px auto" }, playerStyle: { + "display": "flex", + "justify-content": "center", + "align-items": "center", "margin": "0 auto 20px auto", - "height": this.winHeight + "px", + "height": this.winHeight + "px" }, winHeight: window.innerHeight - 240, playTime: null, @@ -178,17 +180,25 @@ }, mounted() { - this.recordListStyle.height = this.winHeight + "px"; - this.playerStyle["height"] = this.winHeight + "px"; - this.chooseDate = moment().format('YYYY-MM-DD') - this.dateChange(); - window.addEventListener('beforeunload', this.stopPlayRecord) + this.$nextTick(() => { + this.updateWinHeight(); + this.chooseDate = moment().format('YYYY-MM-DD') + this.dateChange(); + window.addEventListener('resize',this.updateWinHeight) + window.addEventListener('beforeunload', this.stopPlayRecord) + }) }, destroyed() { this.$destroy('recordVideoPlayer'); window.removeEventListener('beforeunload', this.stopPlayRecord) + window.removeEventListener('resize',this.updateWinHeight) }, methods: { + updateWinHeight(){ + this.winHeight=window.innerHeight - 240; + this.recordListStyle.height = this.winHeight + "px"; + this.playerStyle.height = this.winHeight + "px"; + }, dateChange(){ if (!this.chooseDate) { return; diff --git a/web_src/src/components/common/jessibuca.vue b/web_src/src/components/common/jessibuca.vue index 3419bb590..ef79bab76 100755 --- a/web_src/src/components/common/jessibuca.vue +++ b/web_src/src/components/common/jessibuca.vue @@ -1,23 +1,25 @@