From dcacc1fbcb885a958d6a9715c360ebb4aeac0894 Mon Sep 17 00:00:00 2001 From: 肖洋 <cathay_xy@163.com> Date: 星期二, 17 十二月 2024 19:40:59 +0800 Subject: [PATCH] 新增多个库页面:常温库、分容库、高温库,并更新导航栏以包含这些新页面 --- Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Core/Helper/HttpHelper.cs | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Core/Helper/HttpHelper.cs b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Core/Helper/HttpHelper.cs index 91d5f89..d6982b4 100644 --- a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Core/Helper/HttpHelper.cs +++ b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Core/Helper/HttpHelper.cs @@ -2,6 +2,7 @@ using System.Collections.Generic; using System.Linq; using System.Net.Http.Headers; +using System.Security.Policy; using System.Text; using System.Threading.Tasks; @@ -9,13 +10,16 @@ { public class HttpHelper { - public static async Task<string> GetAsync(string serviceAddress, string contentType = "application/json", Dictionary<string, string>? headers = null) + public static async Task<string> GetAsync(string serviceAddress, Dictionary<string, object> parameters, string contentType = "application/json", Dictionary<string, string>? headers = null) { try { string result = string.Empty; using HttpClient httpClient = new HttpClient(); httpClient.Timeout = new TimeSpan(0, 0, 60); + // 灏嗗弬鏁版嫾鎺ュ埌URL涓� + string queryString = string.Join("&", parameters.Select(x => $"{x.Key}={x.Value}")); + serviceAddress += "?" + queryString; if (headers != null) { -- Gitblit v1.9.3