From c7d5f24fe908d808f2452d415f1b6b301236c442 Mon Sep 17 00:00:00 2001 From: LiuXin Date: Thu, 28 Aug 2025 18:42:10 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=BB=98=E8=AE=A4=E4=B8=BA?= =?UTF-8?q?=E8=BE=85=E7=A0=81=E6=B5=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Common.Shared.Application.csproj | 2 +- .../DaHua/RequestDto/DahuaVideoQueryDto.cs | 4 ++-- .../Video.DomainService/Dahvision/DahuaGeneralCtlService.cs | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/WeiCloud.Fusion/Common.SharedService/Common.Shared.Application/Common.Shared.Application.csproj b/WeiCloud.Fusion/Common.SharedService/Common.Shared.Application/Common.Shared.Application.csproj index 29101b1..d779d21 100644 --- a/WeiCloud.Fusion/Common.SharedService/Common.Shared.Application/Common.Shared.Application.csproj +++ b/WeiCloud.Fusion/Common.SharedService/Common.Shared.Application/Common.Shared.Application.csproj @@ -7,7 +7,7 @@ Common.Shared.Application - 1.0.2 + 2.0.0 zrh-lx zrh-lx 包含所有公共使用的 DTO、契约、接口模型等,供微服务之间共享使用 diff --git a/WeiCloud.Fusion/Common.SharedService/Common.Shared.Application/DaHua/RequestDto/DahuaVideoQueryDto.cs b/WeiCloud.Fusion/Common.SharedService/Common.Shared.Application/DaHua/RequestDto/DahuaVideoQueryDto.cs index 482d466..7ec36c6 100644 --- a/WeiCloud.Fusion/Common.SharedService/Common.Shared.Application/DaHua/RequestDto/DahuaVideoQueryDto.cs +++ b/WeiCloud.Fusion/Common.SharedService/Common.Shared.Application/DaHua/RequestDto/DahuaVideoQueryDto.cs @@ -232,7 +232,7 @@ namespace Common.Shared.Application.DaHua /// 码流类型:1-主码流,2-子码流 /// [JsonPropertyName("streamType")] - public string StreamType { get; set; } + public string StreamType { get; set; } = "2"; /// /// 协议类型:hls,hlss,flv,flvs,ws_flv,wss_flv,rtmp @@ -292,7 +292,7 @@ namespace Common.Shared.Application.DaHua /// 码流类型:1-主码流,2-子码流 /// [JsonPropertyName("streamType")] - public string StreamType { get; set; } + public string StreamType { get; set; } = "2"; /// /// rtsp专用,有datatype没有type,有type没有datatype diff --git a/WeiCloud.Fusion/VideoService/Video.DomainService/Dahvision/DahuaGeneralCtlService.cs b/WeiCloud.Fusion/VideoService/Video.DomainService/Dahvision/DahuaGeneralCtlService.cs index 5f3a217..9eb9948 100644 --- a/WeiCloud.Fusion/VideoService/Video.DomainService/Dahvision/DahuaGeneralCtlService.cs +++ b/WeiCloud.Fusion/VideoService/Video.DomainService/Dahvision/DahuaGeneralCtlService.cs @@ -247,7 +247,7 @@ namespace Video.DomainService { url = $"https://{ipaddress}/evo-apigw/admin/API/video/stream/realtime"; } - + dto.Data.StreamType = "2"; // 3) 用 HttpRequestMessage 发送,才能带上自定义头 using var req = new HttpRequestMessage(HttpMethod.Post, url) { @@ -360,7 +360,7 @@ namespace Video.DomainService _logger.LogWarning("rtsp录像回放:token无效"); return new DaHApiResult { Success = false, Code = "1009", Msg = "token无效" }; } - + dto.Data.StreamType = "2"; var url = $"https://{_configuration["DahuaAuth:Host"]}/evo-apigw/admin/API/SS/Playback/StartPlaybackByTime"; if (ipaddress != null) { @@ -428,7 +428,7 @@ namespace Video.DomainService _logger.LogWarning("rtsp实时预览接口方式:token无效"); return new DaHApiResult { Success = false, Code = "1009", Msg = "token无效" }; } - + dto.Data.StreamType = "2"; var url = $"https://{_configuration["DahuaAuth:Host"]}/evo-apigw/admin/API/MTS/Video/StartVideo"; if (ipaddress != null) {