change post url

This commit is contained in:
Vector Von 2022-06-14 20:43:29 +08:00
parent 474857db7f
commit 9ecf286483
2 changed files with 6 additions and 1 deletions

View File

@ -16,7 +16,7 @@ namespace Topuino_Client_Windows
try try
{ {
HttpContent content = new FormUrlEncodedContent(data); HttpContent content = new FormUrlEncodedContent(data);
HttpResponseMessage response = await client.PostAsync("http://127.0.0.1:7766/putdata", content); HttpResponseMessage response = await client.PostAsync("https://iot.vvzero.com/topuino/putdata", content);
response.EnsureSuccessStatusCode(); response.EnsureSuccessStatusCode();
string responseBody = await response.Content.ReadAsStringAsync(); string responseBody = await response.Content.ReadAsStringAsync();
PublicCommResponse? respData = JsonConvert.DeserializeObject<PublicCommResponse>(responseBody); PublicCommResponse? respData = JsonConvert.DeserializeObject<PublicCommResponse>(responseBody);

View File

@ -6,8 +6,13 @@
<Nullable>enable</Nullable> <Nullable>enable</Nullable>
<UseWPF>true</UseWPF> <UseWPF>true</UseWPF>
<UseWindowsForms>true</UseWindowsForms> <UseWindowsForms>true</UseWindowsForms>
<ApplicationIcon>Topuino.ico</ApplicationIcon>
</PropertyGroup> </PropertyGroup>
<ItemGroup>
<Content Include="Topuino.ico" />
</ItemGroup>
<ItemGroup> <ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" /> <PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
</ItemGroup> </ItemGroup>