Implemetato databese locale con EntityFramework

This commit is contained in:
MarcoE committed 2026-02-17 17:40:33 +01:00
1 parent 544c9e8237
commit e7357bd78a
45 files changed
+989 -119

No files matched your search

@@ -8,7 +8,7 @@ public interface ISteupDataService
Task Init();
List<PuntoVenditaDto> PuntiVenditaList { get; }
InspectionPageState Inspection { get; set; }
InspectionPageState InspectionPageState { get; set; }
List<JtbFasiDto> Reparti { get; }
List<StbActivityTypeDto> TipiAttività { get; }
}
+7 -4
View File
@@ -3,16 +3,19 @@ using SteUp.Shared.Core.Data.Contracts;
using SteUp.Shared.Core.Dto;
using SteUp.Shared.Core.Dto.PageState;
using SteUp.Shared.Core.Interface.IntegryApi;
using SteUp.Shared.Core.Interface.LocalDb;
namespace SteUp.Shared.Core.Data;
public class SteupDataService(
IIntegrySteupService integrySteupService,
IUserSession userSession) : ISteupDataService
IUserSession userSession,
IDbInitializer dbInitializer) : ISteupDataService
{
public Task Init()
public async Task Init()
{
return LoadDataAsync();
await dbInitializer.InitializeAsync();
await LoadDataAsync();
}
private async Task LoadDataAsync()
@@ -24,7 +27,7 @@ public class SteupDataService(
TipiAttività = await integrySteupService.RetrieveActivityType();
}
public InspectionPageState Inspection { get; set; } = new();
public InspectionPageState InspectionPageState { get; set; } = new();
public List<PuntoVenditaDto> PuntiVenditaList { get; private set; } = [];
public List<JtbFasiDto> Reparti { get; private set; } = [];
public List<StbActivityTypeDto> TipiAttività { get; private set; } = [];