From c75815e4f21db5285181fcd96ccf9518dbb23dfc Mon Sep 17 00:00:00 2001
From: ‘liusuyi’ <1951119284@qq.com>
Date: 星期六, 23 十二月 2023 11:13:00 +0800
Subject: [PATCH] 增加接口权限不检验接口
---
ard-work/src/main/java/com/ruoyi/device/tower/controller/ArdTowersController.java | 12 +++++++++++-
ard-work/src/main/java/com/ruoyi/media/controller/VtduController.java | 33 ++++++++++++++++++++++++++++++++-
2 files changed, 43 insertions(+), 2 deletions(-)
diff --git a/ard-work/src/main/java/com/ruoyi/device/tower/controller/ArdTowersController.java b/ard-work/src/main/java/com/ruoyi/device/tower/controller/ArdTowersController.java
index 05acd57..c973a90 100644
--- a/ard-work/src/main/java/com/ruoyi/device/tower/controller/ArdTowersController.java
+++ b/ard-work/src/main/java/com/ruoyi/device/tower/controller/ArdTowersController.java
@@ -51,7 +51,17 @@
List<ArdTowers> list = ardTowersService.selectArdTowersList(ardTowers);
return getDataTable(list);
}
-
+ /**
+ * 鏌ヨ濉旂鐞嗗垪琛�(涓嶆牎楠屾潈闄�)
+ */
+ @GetMapping("/list/noPerm")
+ @ApiOperation(value = "鏌ヨ濉旂鐞嗗垪琛�(涓嶆牎楠屾潈闄�)")
+ public TableDataInfo listNoPerm(ArdTowers ardTowers)
+ {
+ startPage();
+ List<ArdTowers> list = ardTowersService.selectArdTowersList(ardTowers);
+ return getDataTable(list);
+ }
/**
* 瀵煎嚭濉旂鐞嗗垪琛�
*/
diff --git a/ard-work/src/main/java/com/ruoyi/media/controller/VtduController.java b/ard-work/src/main/java/com/ruoyi/media/controller/VtduController.java
index 5bb831b..c052f2a 100644
--- a/ard-work/src/main/java/com/ruoyi/media/controller/VtduController.java
+++ b/ard-work/src/main/java/com/ruoyi/media/controller/VtduController.java
@@ -101,7 +101,38 @@
}
return success(vtdu);
}
-
+ /**
+ * 鑾峰彇娴佸獟浣撶鐞嗚缁嗕俊鎭紙涓嶆牎楠屾潈闄愶級
+ */
+ @GetMapping(value = "/{name}/noPerm")
+ public AjaxResult getInfoNoPerm(@PathVariable("name") String name) {
+ Vtdu vtdu = vtduService.selectVtduByName(name);
+ if (vtdu != null) {
+ String cameraId = name.split("_")[0];
+ Integer chanNo = Integer.valueOf(name.split("_")[1]);
+ CameraCmd cmd = new CameraCmd(cameraId, chanNo);
+ Map<String, Object> videoCompressionCfg = cameraSdkService.getVideoCompressionCfg(cmd);
+ String videoEncType = (String) videoCompressionCfg.get("videoEncType");
+ if (videoEncType != null) {
+ if (!videoEncType.equals("鏍囧噯h264")) {
+ vtdu.setIsCode("1");
+ } else {
+ vtdu.setIsCode("0");
+ }
+ }
+ else
+ {
+ vtdu.setIsCode("0");
+ }
+ //娴佸獟浣撲笉瀛樺湪鏂板锛屽瓨鍦ㄦ洿鏂�
+ if (!mediaService.checkNameExist(name)) {
+ mediaService.addPath(name, vtdu.getRtspSource(), vtdu.getMode(), vtdu.getIsCode());
+ } else {
+ vtduService.updateVtdu(vtdu);
+ }
+ }
+ return success(vtdu);
+ }
/**
* 鏂板娴佸獟浣撶鐞�
*/
--
Gitblit v1.9.3