|
|
@ -9,6 +9,7 @@ using BlazorShared.Attributes; |
|
|
using BlazorShared.Interfaces; |
|
|
using BlazorShared.Interfaces; |
|
|
using BlazorShared.Models; |
|
|
using BlazorShared.Models; |
|
|
using Microsoft.Extensions.Logging; |
|
|
using Microsoft.Extensions.Logging; |
|
|
|
|
|
using Microsoft.Extensions.Options; |
|
|
|
|
|
|
|
|
namespace BlazorAdmin.Services; |
|
|
namespace BlazorAdmin.Services; |
|
|
|
|
|
|
|
|
@ -23,12 +24,12 @@ public class CatalogLookupDataService<TLookupData, TReponse> |
|
|
private readonly string _apiUrl; |
|
|
private readonly string _apiUrl; |
|
|
|
|
|
|
|
|
public CatalogLookupDataService(HttpClient httpClient, |
|
|
public CatalogLookupDataService(HttpClient httpClient, |
|
|
BaseUrlConfiguration baseUrlConfiguration, |
|
|
IOptions<BaseUrlConfiguration> baseUrlConfiguration, |
|
|
ILogger<CatalogLookupDataService<TLookupData, TReponse>> logger) |
|
|
ILogger<CatalogLookupDataService<TLookupData, TReponse>> logger) |
|
|
{ |
|
|
{ |
|
|
_httpClient = httpClient; |
|
|
_httpClient = httpClient; |
|
|
_logger = logger; |
|
|
_logger = logger; |
|
|
_apiUrl = baseUrlConfiguration.ApiBase; |
|
|
_apiUrl = baseUrlConfiguration.Value.ApiBase; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public async Task<List<TLookupData>> List() |
|
|
public async Task<List<TLookupData>> List() |
|
|
|