feat: Aggiunto sistema completo di gestione profili per Data Coupler

- Creata nuova libreria Components con componenti Blazor riutilizzabili
  * ProfileSelector: dropdown per selezione profili salvati
  * ProfileSaver: componente per salvare configurazioni correnti come profili
  * ProfileManagement: modale per gestione profili salvati
  * ProfileQuickActions: bottoni azioni rapide per operazioni sui profili

- Esteso CredentialManager con entità e servizi per DataCouplerProfile
  * Aggiunto modello DataCouplerProfile con configurazioni mapping e metadati
  * Implementata migrazione Entity Framework per memorizzazione profili
  * Creato DataCouplerProfileService per operazioni CRUD
  * Aggiunto CredentialDbContextFactory per operazioni database design-time

- Migliorato componente principale DataCoupler con integrazione profili
  * Integrata funzionalità caricamento/salvataggio profili
  * Aggiunto selettore profili nella parte superiore dell'interfaccia
  * Mantenuta retrocompatibilità con funzionalità esistenti
  * Migliorata esperienza utente con gestione configurazioni salvate

- Aggiornata struttura progetto e dipendenze
  * Aggiunto progetto Components alla soluzione
  * Aggiornati riferimenti progetti e import
  * Rimosso progetto obsoleto TestDatabaseFix

Questo aggiornamento migliora significativamente il flusso di lavoro permettendo agli utenti di salvare, caricare e gestire configurazioni complete di accoppiamento dati come
This commit is contained in:
2025-07-02 00:00:05 +02:00
parent 1435c013d3
commit 7e450a358b
34 changed files with 2430 additions and 422 deletions
@@ -0,0 +1,60 @@
namespace CredentialManager.Models;
/// <summary>
/// DTO per la creazione/aggiornamento di un profilo DataCoupler
/// </summary>
public class DataCouplerProfileDto
{
public int? Id { get; set; }
public string Name { get; set; } = string.Empty;
public string? Description { get; set; }
// Informazioni sorgente
public string SourceType { get; set; } = string.Empty;
public int? SourceCredentialId { get; set; }
public string? SourceSchema { get; set; }
public string? SourceTable { get; set; }
public string? SourceFilePath { get; set; }
// Informazioni destinazione
public string DestinationType { get; set; } = string.Empty;
public int? DestinationCredentialId { get; set; }
public string? DestinationSchema { get; set; }
public string? DestinationTable { get; set; }
public string? DestinationEndpoint { get; set; }
// Mapping dei campi
public List<FieldMappingDto>? FieldMappings { get; set; }
}
/// <summary>
/// DTO per il mapping dei campi
/// </summary>
public class FieldMappingDto
{
public string SourceField { get; set; } = string.Empty;
public string DestinationField { get; set; } = string.Empty;
public string? DataType { get; set; }
public bool IsKey { get; set; }
public bool IsRequired { get; set; }
public string? DefaultValue { get; set; }
public string? Transformation { get; set; }
}
/// <summary>
/// DTO per la visualizzazione di un profilo nella lista
/// </summary>
public class DataCouplerProfileSummaryDto
{
public int Id { get; set; }
public string Name { get; set; } = string.Empty;
public string? Description { get; set; }
public string SourceType { get; set; } = string.Empty;
public string? SourceName { get; set; }
public string DestinationType { get; set; } = string.Empty;
public string? DestinationName { get; set; }
public DateTime CreatedAt { get; set; }
public DateTime? LastUsedAt { get; set; }
public string? CreatedBy { get; set; }
public bool IsActive { get; set; }
}