Commit 65e3d96d authored by maoying's avatar maoying

修改视频接口url参数返回

parent 38285704
...@@ -515,18 +515,19 @@ public class VideoServiceImpl extends ServiceImpl<VideoMapper, Video> implements ...@@ -515,18 +515,19 @@ public class VideoServiceImpl extends ServiceImpl<VideoMapper, Video> implements
@Override @Override
public List<Video> listByCode(String code) { public List<Video> listByCode(String code) {
return videoMapper.listByCode(code); return videoMapper.listByCode(code);
} }
@Override @Override
public String getVideoUrl(String videoId, String presetIndex, String defaultUrl, String code) { public String getVideoUrl(String videoId, String presetIndex, String defaultUrl, String code) {
String url = "";
if ("hls".equals(vedioFormat)) { if ("hls".equals(vedioFormat)) {
String url = getVideoUrl(code); url = getVideoUrl(code);
return ObjectUtils.isEmpty(url) ? defaultUrl : url; } else {
url = getFlvUrlByVideoIdOrPresetIndex(videoId, presetIndex);
} }
return getFlvUrlByVideoIdOrPresetIndex(videoId, presetIndex); return ObjectUtils.isEmpty(url) ? defaultUrl : url;
} }
private String getVideoUrl(String code){ private String getVideoUrl(String code){
...@@ -570,7 +571,7 @@ public class VideoServiceImpl extends ServiceImpl<VideoMapper, Video> implements ...@@ -570,7 +571,7 @@ public class VideoServiceImpl extends ServiceImpl<VideoMapper, Video> implements
} catch (Exception e) { } catch (Exception e) {
log.error("flv视频流接口获取失败:{}", e.getMessage()); log.error("flv视频流接口获取失败:{}", e.getMessage());
} }
return "flvUrl"; return "";
} }
...@@ -592,7 +593,7 @@ public class VideoServiceImpl extends ServiceImpl<VideoMapper, Video> implements ...@@ -592,7 +593,7 @@ public class VideoServiceImpl extends ServiceImpl<VideoMapper, Video> implements
if (respond.containsKey("rtsp")) { if (respond.containsKey("rtsp")) {
return respond.get("rtsp"); return respond.get("rtsp");
} }
return "rtsp"; return "";
} }
} }
...@@ -350,8 +350,7 @@ ...@@ -350,8 +350,7 @@
wl_equipment_specific_alarm_log wlesal wl_equipment_specific_alarm_log wlesal
LEFT JOIN wl_equipment we ON wlesal.equipment_code = we.code LEFT JOIN wl_equipment we ON wlesal.equipment_code = we.code
LEFT JOIN wl_equipment_specific_alarm wlesa ON wlesa.id = wlesal.equipment_specific_alarm_id) d LEFT JOIN wl_equipment_specific_alarm wlesa ON wlesa.id = wlesal.equipment_specific_alarm_id) d
WHERE 1=1 WHERE d.fireEquipmentName IS NOT NULL
AND d.fireEquipmentName IS NOT NULL
<if test="param.warehouseStructureName != null and param.warehouseStructureName != ''">and <if test="param.warehouseStructureName != null and param.warehouseStructureName != ''">and
d.warehouseStructureName like d.warehouseStructureName like
concat(concat("%",#{param.warehouseStructureName}),"%") concat(concat("%",#{param.warehouseStructureName}),"%")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment