2023-06-27
This commit is contained in:
@@ -132,6 +132,9 @@
|
||||
'UrlStr': url,
|
||||
'PCUrl': '<%=PCUrl%>',
|
||||
},
|
||||
headers: {
|
||||
'token': '<%=UserId%>'
|
||||
},
|
||||
dataType: 'json',
|
||||
async: false,
|
||||
success: function (json) {
|
||||
|
||||
@@ -153,7 +153,7 @@ namespace WebAPI.Controllers
|
||||
HttpClient _httpClient = new HttpClient();
|
||||
try
|
||||
{
|
||||
System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12;
|
||||
// System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12;
|
||||
// 发送 GET 请求以获取文件内容
|
||||
var response = await _httpClient.GetAsync(toDoItem.UrlStr);
|
||||
response.EnsureSuccessStatusCode();
|
||||
|
||||
Reference in New Issue
Block a user