调整代码对通道类型的调用

This commit is contained in:
648540858
2024-12-23 18:37:24 +08:00
parent 19453f7ca9
commit 59e3175f00
6 changed files with 24 additions and 20 deletions

View File

@@ -550,4 +550,6 @@ public interface CommonGBChannelMapper {
@Param("channelType") Integer channelType, @Param("online") Boolean online,
@Param("hasLink") Boolean hasLink);
@SelectProvider(type = ChannelProvider.class, method = "queryByDataId")
CommonGBChannel queryByDataId(@Param("dataType") Integer dataType, @Param("dataDeviceId") Integer dataDeviceId);
}

View File

@@ -113,6 +113,10 @@ public class ChannelProvider {
return BASE_SQL + " where channel_type = 0 and stream_push_id = #{streamPushId}";
}
public String queryByDataId(Map<String, Object> params ){
return BASE_SQL + " where data_type = #{dataType} and data_device_id = #{dataDeviceId}";
}
public String queryByStreamProxyId(Map<String, Object> params ){
return BASE_SQL + " where channel_type = 0 and stream_proxy_id = #{streamProxyId}";
}