Updated daily report to show correct information when two work weeks split quarters.
Also current changes to project with Blazor implementation is implemented here as well.
This commit is contained in:
19
ReportingServices.Shared.Blazor/HelperClasses/ApiCaller.cs
Normal file
19
ReportingServices.Shared.Blazor/HelperClasses/ApiCaller.cs
Normal file
@ -0,0 +1,19 @@
|
||||
using System.Text.Json;
|
||||
|
||||
namespace ReportingServices.Shared.Blazor.HelperClasses;
|
||||
|
||||
public static class ApiCaller
|
||||
{
|
||||
public static async Task<T> GetApi<T>(string url)
|
||||
{
|
||||
T deserializedJson = default;
|
||||
|
||||
using (HttpClient client = new())
|
||||
{
|
||||
string apiResponse = await client.GetStringAsync(url);
|
||||
deserializedJson = JsonSerializer.Deserialize<T>(apiResponse);
|
||||
}
|
||||
|
||||
return deserializedJson;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user