diff --git a/src/main/java/com/genersoft/iot/vmp/vmanager/gb28181/media/MediaController.java b/src/main/java/com/genersoft/iot/vmp/vmanager/gb28181/media/MediaController.java index 812e0444..d135fa2f 100644 --- a/src/main/java/com/genersoft/iot/vmp/vmanager/gb28181/media/MediaController.java +++ b/src/main/java/com/genersoft/iot/vmp/vmanager/gb28181/media/MediaController.java @@ -10,7 +10,6 @@ import com.genersoft.iot.vmp.service.IStreamProxyService; import com.genersoft.iot.vmp.storager.IRedisCatchStorage; import com.genersoft.iot.vmp.vmanager.bean.ErrorCode; import com.genersoft.iot.vmp.vmanager.bean.StreamContent; -import com.genersoft.iot.vmp.vmanager.bean.WVPResult; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.Parameter; import io.swagger.v3.oas.annotations.tags.Tag; @@ -89,7 +88,6 @@ public class MediaController { streamInfo = mediaService.getStreamInfoByAppAndStreamWithCheck(app, stream, mediaServerId, authority); } - WVPResult result = new WVPResult<>(); if (streamInfo != null){ return new StreamContent(streamInfo); }else { diff --git a/src/main/java/com/genersoft/iot/vmp/web/gb28181/ApiDeviceController.java b/src/main/java/com/genersoft/iot/vmp/web/gb28181/ApiDeviceController.java index 48dbbc44..a5458b05 100644 --- a/src/main/java/com/genersoft/iot/vmp/web/gb28181/ApiDeviceController.java +++ b/src/main/java/com/genersoft/iot/vmp/web/gb28181/ApiDeviceController.java @@ -94,6 +94,7 @@ public class ApiDeviceController { @RequestMapping(value = "/channellist") public JSONObject channellist( String serial, + @RequestParam(required = false)String code, @RequestParam(required = false)String channel_type, @RequestParam(required = false)String dir_serial , @RequestParam(required = false)Integer start, @@ -148,9 +149,9 @@ public class ApiDeviceController { // 1-IETF RFC3261, // 2-基于口令的双向认证, // 3-基于数字证书的双向认证 - deviceJOSNChannel.put("Status", deviceChannel.getStatus()); - deviceJOSNChannel.put("Longitude", deviceChannel.getLongitudeWgs84()); - deviceJOSNChannel.put("Latitude", deviceChannel.getLatitudeWgs84()); + deviceJOSNChannel.put("Status", deviceChannel.getStatus() == 1 ? "ON":"OFF"); + deviceJOSNChannel.put("Longitude", deviceChannel.getLongitude()); + deviceJOSNChannel.put("Latitude", deviceChannel.getLatitude()); deviceJOSNChannel.put("PTZType ", deviceChannel.getPTZType()); // 云台类型, 0 - 未知, 1 - 球机, 2 - 半球, // 3 - 固定枪机, 4 - 遥控枪机 deviceJOSNChannel.put("CustomPTZType", "");