Browse Source

相机回放视频过滤排序

hexiao 2 years ago
parent
commit
ea7bbcfa97

+ 1 - 1
hazard-admin/src/main/java/com/ozs/web/controller/accountmanagment/BaseCameraManagementController.java

@@ -335,7 +335,7 @@ public class BaseCameraManagementController extends BaseController {
         if (ObjectUtils.isEmpty(one)) {
             throw new BaseException("相机编号【" + vo.getCameraCode() + "】不存在");
         }
-        return success(CameraUtil.historyPlayList(one.getChannel(), vo.getStartTime(), vo.getEntTime()));
+        return success(CameraUtil.historyPlayList(one.getChannel(), vo.getStartTime(), vo.getEntTime(), "http://47.106.159.135/"));
     }
 
     @ApiOperation("播放回放")

+ 2 - 2
hazard-admin/src/main/java/com/ozs/web/core/util/CameraUtil.java

@@ -80,7 +80,7 @@ public class CameraUtil {
 
 
     public static String historyPlayListStr(String channel, Date startTm, Date endTm) {
-        List<String> list = historyPlayList(channel, startTm, endTm);
+        List<String> list = historyPlayList(channel, startTm, endTm, mappingUrl);
         String ph = "/flv/" + DateUtils.parseDateToStr(DateUtils.YYYYMMDDHHMMSS, new Date())
                 + "/" + channel + "/"
                 + UUID.randomUUID().toString() + ".flv";
@@ -94,7 +94,7 @@ public class CameraUtil {
     }
 
 
-    public static List<String> historyPlayList(String channel, Date startTm, Date endTm) {
+    public static List<String> historyPlayList(String channel, Date startTm, Date endTm, String mappingUrl) {
         if (StringUtils.isBlank(channel)
                 || ObjectUtils.isEmpty(startTm)
                 || ObjectUtils.isEmpty(endTm)) {

+ 1 - 0
hazard-admin/src/main/resources/application.yml

@@ -18,6 +18,7 @@ base:
   #  path: http://47.106.159.135:8554
   path: http://47.106.159.135:8554
   ffmpegPath: /usr/local/ffmpeg/bin/ffmpeg
+  mappingUrl: /opt/streams/
 
 # 开发环境配置
 server: