Files
zentral/src/backend/Zentral.Infrastructure/Migrations/20251212143625_AddTrainingModule.Designer.cs

4893 lines
166 KiB
C#

// <auto-generated />
using System;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using Zentral.Infrastructure.Data;
#nullable disable
namespace Zentral.Infrastructure.Migrations
{
[DbContext(typeof(ZentralDbContext))]
[Migration("20251212143625_AddTrainingModule")]
partial class AddTrainingModule
{
/// <inheritdoc />
protected override void BuildTargetModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "9.0.0");
modelBuilder.Entity("Zentral.Domain.Entities.App", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<decimal>("BasePrice")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Dependencies")
.HasColumnType("TEXT");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<string>("Icon")
.HasColumnType("TEXT");
b.Property<bool>("IsAvailable")
.HasColumnType("INTEGER");
b.Property<bool>("IsCore")
.HasColumnType("INTEGER");
b.Property<decimal>("MonthlyMultiplier")
.HasPrecision(5, 2)
.HasColumnType("TEXT");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("RoutePath")
.HasColumnType("TEXT");
b.Property<int>("SortOrder")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("SortOrder");
b.ToTable("Apps");
});
modelBuilder.Entity("Zentral.Domain.Entities.AppSubscription", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("AppId")
.HasColumnType("INTEGER");
b.Property<bool>("AutoRenew")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime?>("EndDate")
.HasColumnType("TEXT");
b.Property<bool>("IsEnabled")
.HasColumnType("INTEGER");
b.Property<DateTime?>("LastRenewalDate")
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<decimal?>("PaidPrice")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<DateTime?>("StartDate")
.HasColumnType("TEXT");
b.Property<int>("SubscriptionType")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("AppId")
.IsUnique();
b.ToTable("AppSubscriptions");
});
modelBuilder.Entity("Zentral.Domain.Entities.Articolo", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<int?>("CategoriaId")
.HasColumnType("INTEGER");
b.Property<string>("Codice")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("CodiceAlternativo")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int?>("GiorniValidita")
.HasColumnType("INTEGER");
b.Property<byte[]>("Immagine")
.HasColumnType("BLOB");
b.Property<string>("MimeType")
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<decimal?>("QtaDisponibile")
.HasColumnType("TEXT");
b.Property<decimal?>("QtaStdA")
.HasColumnType("TEXT");
b.Property<decimal?>("QtaStdB")
.HasColumnType("TEXT");
b.Property<decimal?>("QtaStdS")
.HasColumnType("TEXT");
b.Property<int?>("TipoMaterialeId")
.HasColumnType("INTEGER");
b.Property<string>("UnitaMisura")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("CategoriaId");
b.HasIndex("Codice")
.IsUnique();
b.HasIndex("TipoMaterialeId");
b.ToTable("Articoli");
});
modelBuilder.Entity("Zentral.Domain.Entities.AutoCode", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<string>("EntityCode")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("EntityName")
.IsRequired()
.HasColumnType("TEXT");
b.Property<bool>("IsEnabled")
.HasColumnType("INTEGER");
b.Property<bool>("IsReadOnly")
.HasColumnType("INTEGER");
b.Property<int?>("LastResetMonth")
.HasColumnType("INTEGER");
b.Property<int?>("LastResetYear")
.HasColumnType("INTEGER");
b.Property<long>("LastSequence")
.HasColumnType("INTEGER");
b.Property<string>("ModuleCode")
.HasColumnType("TEXT");
b.Property<string>("Pattern")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Prefix")
.HasColumnType("TEXT");
b.Property<bool>("ResetSequenceMonthly")
.HasColumnType("INTEGER");
b.Property<bool>("ResetSequenceYearly")
.HasColumnType("INTEGER");
b.Property<int>("SortOrder")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("EntityCode")
.IsUnique();
b.HasIndex("ModuleCode");
b.ToTable("AutoCodes");
});
modelBuilder.Entity("Zentral.Domain.Entities.Cliente", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Cap")
.HasColumnType("TEXT");
b.Property<string>("Citta")
.HasColumnType("TEXT");
b.Property<string>("Codice")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("CodiceAlternativo")
.HasColumnType("TEXT");
b.Property<string>("CodiceDestinatario")
.HasColumnType("TEXT");
b.Property<string>("CodiceFiscale")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Email")
.HasColumnType("TEXT");
b.Property<string>("Indirizzo")
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<string>("PartitaIva")
.HasColumnType("TEXT");
b.Property<string>("Pec")
.HasColumnType("TEXT");
b.Property<string>("Provincia")
.HasColumnType("TEXT");
b.Property<string>("RagioneSociale")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Telefono")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("PartitaIva");
b.HasIndex("RagioneSociale");
b.ToTable("Clienti");
});
modelBuilder.Entity("Zentral.Domain.Entities.ClienteContatto", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ClienteId")
.HasColumnType("INTEGER");
b.Property<string>("Cognome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Email")
.HasColumnType("TEXT");
b.Property<string>("Nome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Ruolo")
.HasColumnType("TEXT");
b.Property<string>("Telefono")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ClienteId");
b.ToTable("ClienteContatti", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.CodiceCategoria", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Codice")
.IsRequired()
.HasColumnType("TEXT");
b.Property<decimal>("CoeffA")
.HasColumnType("TEXT");
b.Property<decimal>("CoeffB")
.HasColumnType("TEXT");
b.Property<decimal>("CoeffS")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("CodiciCategoria");
});
modelBuilder.Entity("Zentral.Domain.Entities.Communications.EmailLog", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("ErrorMessage")
.HasColumnType("TEXT");
b.Property<string>("Recipient")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Sender")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime>("SentDate")
.HasColumnType("TEXT");
b.Property<string>("Status")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Subject")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Recipient");
b.HasIndex("SentDate");
b.HasIndex("Status");
b.ToTable("EmailLogs", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Configurazione", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Chiave")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<string>("Valore")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Chiave")
.IsUnique();
b.ToTable("Configurazioni");
});
modelBuilder.Entity("Zentral.Domain.Entities.CustomFieldDefinition", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("DefaultValue")
.HasColumnType("TEXT");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<string>("EntityName")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("FieldName")
.IsRequired()
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<bool>("IsRequired")
.HasColumnType("INTEGER");
b.Property<string>("Label")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("OptionsJson")
.HasColumnType("TEXT");
b.Property<string>("Placeholder")
.HasColumnType("TEXT");
b.Property<int>("SortOrder")
.HasColumnType("INTEGER");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<string>("ValidationRegex")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("EntityName");
b.HasIndex("EntityName", "FieldName")
.IsUnique();
b.ToTable("CustomFieldDefinitions");
});
modelBuilder.Entity("Zentral.Domain.Entities.Evento", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int?>("ClienteId")
.HasColumnType("INTEGER");
b.Property<string>("Codice")
.HasColumnType("TEXT");
b.Property<bool>("Confermato")
.HasColumnType("INTEGER");
b.Property<decimal?>("CostoPersona")
.HasColumnType("TEXT");
b.Property<decimal?>("CostoTotale")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime>("DataEvento")
.HasColumnType("TEXT");
b.Property<DateTime?>("DataScadenzaPreventivo")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.HasColumnType("TEXT");
b.Property<int?>("LocationId")
.HasColumnType("INTEGER");
b.Property<string>("NoteAllestimento")
.HasColumnType("TEXT");
b.Property<string>("NoteCliente")
.HasColumnType("TEXT");
b.Property<string>("NoteCucina")
.HasColumnType("TEXT");
b.Property<string>("NoteInterne")
.HasColumnType("TEXT");
b.Property<int?>("NumeroOspiti")
.HasColumnType("INTEGER");
b.Property<int?>("NumeroOspitiAdulti")
.HasColumnType("INTEGER");
b.Property<int?>("NumeroOspitiBambini")
.HasColumnType("INTEGER");
b.Property<int?>("NumeroOspitiBuffet")
.HasColumnType("INTEGER");
b.Property<int?>("NumeroOspitiSeduti")
.HasColumnType("INTEGER");
b.Property<TimeSpan?>("OraFine")
.HasColumnType("TEXT");
b.Property<TimeSpan?>("OraInizio")
.HasColumnType("TEXT");
b.Property<decimal?>("Saldo")
.HasColumnType("TEXT");
b.Property<int>("Stato")
.HasColumnType("INTEGER");
b.Property<int?>("TipoEventoId")
.HasColumnType("INTEGER");
b.Property<decimal?>("TotaleAcconti")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ClienteId");
b.HasIndex("Codice");
b.HasIndex("DataEvento");
b.HasIndex("LocationId");
b.HasIndex("Stato");
b.HasIndex("TipoEventoId");
b.ToTable("Eventi");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoAcconto", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("AConferma")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime?>("DataPagamento")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.HasColumnType("TEXT");
b.Property<int>("EventoId")
.HasColumnType("INTEGER");
b.Property<decimal>("Importo")
.HasColumnType("TEXT");
b.Property<string>("MetodoPagamento")
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<int>("Ordine")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("EventoId");
b.ToTable("EventiAcconti");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoAllegato", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<byte[]>("Contenuto")
.HasColumnType("BLOB");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int>("EventoId")
.HasColumnType("INTEGER");
b.Property<string>("MimeType")
.HasColumnType("TEXT");
b.Property<string>("NomeFile")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("EventoId");
b.ToTable("EventiAllegati");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoAltroCosto", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<decimal>("AliquotaIva")
.HasColumnType("TEXT");
b.Property<bool>("ApplicaIva")
.HasColumnType("INTEGER");
b.Property<decimal>("CostoUnitario")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int>("EventoId")
.HasColumnType("INTEGER");
b.Property<int>("Ordine")
.HasColumnType("INTEGER");
b.Property<decimal>("Quantita")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("EventoId");
b.ToTable("EventiAltriCosti");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoDegustazione", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Completata")
.HasColumnType("INTEGER");
b.Property<decimal?>("CostoDegustazione")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime>("DataDegustazione")
.HasColumnType("TEXT");
b.Property<bool>("Detraibile")
.HasColumnType("INTEGER");
b.Property<int>("EventoId")
.HasColumnType("INTEGER");
b.Property<string>("Luogo")
.HasColumnType("TEXT");
b.Property<string>("Menu")
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<int?>("NumeroPaganti")
.HasColumnType("INTEGER");
b.Property<int?>("NumeroPersone")
.HasColumnType("INTEGER");
b.Property<TimeSpan?>("Ora")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("EventoId");
b.ToTable("EventiDegustazioni");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoDettaglioOspiti", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<decimal?>("CostoUnitario")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int>("EventoId")
.HasColumnType("INTEGER");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<int>("Numero")
.HasColumnType("INTEGER");
b.Property<int>("Ordine")
.HasColumnType("INTEGER");
b.Property<decimal?>("Sconto")
.HasColumnType("TEXT");
b.Property<int>("TipoOspiteId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("EventoId");
b.HasIndex("TipoOspiteId");
b.ToTable("EventiDettaglioOspiti");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoDettaglioPrelievo", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticoloId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int>("EventoId")
.HasColumnType("INTEGER");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<decimal?>("QtaCalcolata")
.HasColumnType("TEXT");
b.Property<decimal?>("QtaEffettiva")
.HasColumnType("TEXT");
b.Property<decimal?>("QtaRichiesta")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticoloId");
b.HasIndex("EventoId");
b.ToTable("EventiDettaglioPrelievo");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoDettaglioRisorsa", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<decimal?>("Costo")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int>("EventoId")
.HasColumnType("INTEGER");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<TimeSpan?>("OraFine")
.HasColumnType("TEXT");
b.Property<TimeSpan?>("OraInizio")
.HasColumnType("TEXT");
b.Property<decimal?>("OreLavoro")
.HasColumnType("TEXT");
b.Property<int>("RisorsaId")
.HasColumnType("INTEGER");
b.Property<string>("Ruolo")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("EventoId");
b.HasIndex("RisorsaId");
b.ToTable("EventiDettaglioRisorse");
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Assenza", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime>("DataFine")
.HasColumnType("TEXT");
b.Property<DateTime>("DataInizio")
.HasColumnType("TEXT");
b.Property<int>("DipendenteId")
.HasColumnType("INTEGER");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<string>("Stato")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("TipoAssenza")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("DipendenteId");
b.ToTable("Assenze", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Contratto", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime?>("DataFine")
.HasColumnType("TEXT");
b.Property<DateTime>("DataInizio")
.HasColumnType("TEXT");
b.Property<int>("DipendenteId")
.HasColumnType("INTEGER");
b.Property<string>("Livello")
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<decimal>("RetribuzioneLorda")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<string>("TipoContratto")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("DipendenteId");
b.ToTable("Contratti", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Dipendente", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("CodiceFiscale")
.HasColumnType("TEXT");
b.Property<string>("Cognome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime?>("DataNascita")
.HasColumnType("TEXT");
b.Property<string>("Email")
.HasColumnType("TEXT");
b.Property<string>("Indirizzo")
.HasColumnType("TEXT");
b.Property<string>("Nome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Ruolo")
.HasColumnType("TEXT");
b.Property<string>("Telefono")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("CodiceFiscale")
.IsUnique();
b.ToTable("Dipendenti", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Pagamento", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime>("DataPagamento")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int>("DipendenteId")
.HasColumnType("INTEGER");
b.Property<decimal>("ImportoNetto")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<bool>("Pagato")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("DipendenteId");
b.ToTable("Pagamenti", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Rimborso", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime>("DataSpesa")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int>("DipendenteId")
.HasColumnType("INTEGER");
b.Property<decimal>("Importo")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<string>("Stato")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("DipendenteId");
b.ToTable("Rimborsi", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Location", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Cap")
.HasColumnType("TEXT");
b.Property<string>("Citta")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<decimal?>("DistanzaKm")
.HasColumnType("TEXT");
b.Property<string>("Email")
.HasColumnType("TEXT");
b.Property<string>("Indirizzo")
.HasColumnType("TEXT");
b.Property<string>("Nome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<string>("Provincia")
.HasColumnType("TEXT");
b.Property<string>("Referente")
.HasColumnType("TEXT");
b.Property<string>("Telefono")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Nome");
b.ToTable("Location");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.BillOfMaterials", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.IsRequired()
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("IsActive");
b.ToTable("BillOfMaterials", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.BillOfMaterialsComponent", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("BillOfMaterialsId")
.HasColumnType("INTEGER");
b.Property<int>("ComponentArticleId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("ScrapPercentage")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("BillOfMaterialsId");
b.HasIndex("ComponentArticleId");
b.ToTable("BillOfMaterialsComponents", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.MrpSuggestion", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<DateTime>("CalculationDate")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<bool>("IsProcessed")
.HasColumnType("INTEGER");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<string>("Reason")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime>("SuggestionDate")
.HasColumnType("TEXT");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("CalculationDate");
b.HasIndex("IsProcessed");
b.ToTable("MrpSuggestions", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionCycle", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<bool>("IsDefault")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("IsActive");
b.ToTable("ProductionCycles", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionCyclePhase", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<int>("DurationPerUnitMinutes")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int>("ProductionCycleId")
.HasColumnType("INTEGER");
b.Property<int>("Sequence")
.HasColumnType("INTEGER");
b.Property<int>("SetupTimeMinutes")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("WorkCenterId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("ProductionCycleId");
b.HasIndex("WorkCenterId");
b.ToTable("ProductionCyclePhases", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionOrder", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime>("DueDate")
.HasColumnType("TEXT");
b.Property<DateTime?>("EndDate")
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<int?>("ParentProductionOrderId")
.HasColumnType("INTEGER");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime>("StartDate")
.HasColumnType("TEXT");
b.Property<int>("Status")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("ParentProductionOrderId");
b.HasIndex("StartDate");
b.HasIndex("Status");
b.ToTable("ProductionOrders", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionOrderComponent", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<decimal>("ConsumedQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int>("ProductionOrderId")
.HasColumnType("INTEGER");
b.Property<decimal>("RequiredQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("ProductionOrderId");
b.ToTable("ProductionOrderComponents", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionOrderPhase", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ActualDurationMinutes")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime?>("EndDate")
.HasColumnType("TEXT");
b.Property<int>("EstimatedDurationMinutes")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int>("ProductionOrderId")
.HasColumnType("INTEGER");
b.Property<decimal>("QuantityCompleted")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("QuantityScrapped")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("Sequence")
.HasColumnType("INTEGER");
b.Property<DateTime?>("StartDate")
.HasColumnType("TEXT");
b.Property<int>("Status")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("WorkCenterId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("ProductionOrderId");
b.HasIndex("Status");
b.HasIndex("WorkCenterId");
b.ToTable("ProductionOrderPhases", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.WorkCenter", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<decimal>("CostPerHour")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("IsActive");
b.ToTable("WorkCenters", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Purchases.PurchaseOrder", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int?>("DestinationWarehouseId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("ExpectedDeliveryDate")
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<DateTime>("OrderDate")
.HasColumnType("TEXT");
b.Property<string>("OrderNumber")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int>("Status")
.HasColumnType("INTEGER");
b.Property<int>("SupplierId")
.HasColumnType("INTEGER");
b.Property<decimal>("TotalGross")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("TotalNet")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("TotalTax")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("DestinationWarehouseId");
b.HasIndex("OrderDate");
b.HasIndex("OrderNumber")
.IsUnique();
b.HasIndex("Status");
b.HasIndex("SupplierId");
b.ToTable("PurchaseOrders", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Purchases.PurchaseOrderLine", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.IsRequired()
.HasColumnType("TEXT");
b.Property<decimal>("DiscountPercent")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<decimal>("LineTotal")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("PurchaseOrderId")
.HasColumnType("INTEGER");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("ReceivedQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("TaxRate")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<decimal>("UnitPrice")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("WarehouseArticleId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("PurchaseOrderId");
b.HasIndex("WarehouseArticleId");
b.ToTable("PurchaseOrderLines", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Purchases.Supplier", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Address")
.HasColumnType("TEXT");
b.Property<string>("City")
.HasColumnType("TEXT");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Country")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Email")
.HasColumnType("TEXT");
b.Property<string>("FiscalCode")
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<string>("PaymentTerms")
.HasColumnType("TEXT");
b.Property<string>("Pec")
.HasColumnType("TEXT");
b.Property<string>("Phone")
.HasColumnType("TEXT");
b.Property<string>("Province")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<string>("VatNumber")
.HasColumnType("TEXT");
b.Property<string>("Website")
.HasColumnType("TEXT");
b.Property<string>("ZipCode")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("IsActive");
b.HasIndex("Name");
b.HasIndex("VatNumber");
b.ToTable("Suppliers", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.ReportFont", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<long>("FileSize")
.HasColumnType("INTEGER");
b.Property<byte[]>("FontData")
.IsRequired()
.HasColumnType("BLOB");
b.Property<string>("FontFamily")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("FontStyle")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("MimeType")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Nome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("FontFamily");
b.ToTable("ReportFonts");
});
modelBuilder.Entity("Zentral.Domain.Entities.ReportImage", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Categoria")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<long>("FileSize")
.HasColumnType("INTEGER");
b.Property<int>("Height")
.HasColumnType("INTEGER");
b.Property<byte[]>("ImageData")
.IsRequired()
.HasColumnType("BLOB");
b.Property<string>("MimeType")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Nome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("Width")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("Categoria");
b.ToTable("ReportImages");
});
modelBuilder.Entity("Zentral.Domain.Entities.ReportTemplate", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Categoria")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.HasColumnType("TEXT");
b.Property<string>("Nome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Orientation")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("PageSize")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("TemplateJson")
.IsRequired()
.HasColumnType("TEXT");
b.Property<byte[]>("Thumbnail")
.HasColumnType("BLOB");
b.Property<string>("ThumbnailMimeType")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Categoria");
b.HasIndex("Nome");
b.ToTable("ReportTemplates");
});
modelBuilder.Entity("Zentral.Domain.Entities.Risorsa", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Cognome")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Email")
.HasColumnType("TEXT");
b.Property<string>("Nome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<string>("Telefono")
.HasColumnType("TEXT");
b.Property<int?>("TipoRisorsaId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("TipoRisorsaId");
b.ToTable("Risorse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Sales.SalesOrder", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int>("CustomerId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("ExpectedDeliveryDate")
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<DateTime>("OrderDate")
.HasColumnType("TEXT");
b.Property<string>("OrderNumber")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int>("Status")
.HasColumnType("INTEGER");
b.Property<decimal>("TotalGross")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("TotalNet")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("TotalTax")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("CustomerId");
b.HasIndex("OrderDate");
b.HasIndex("OrderNumber")
.IsUnique();
b.HasIndex("Status");
b.ToTable("SalesOrders", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Sales.SalesOrderLine", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.IsRequired()
.HasColumnType("TEXT");
b.Property<decimal>("DiscountPercent")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<decimal>("LineTotal")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("SalesOrderId")
.HasColumnType("INTEGER");
b.Property<decimal>("ShippedQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("TaxRate")
.HasPrecision(18, 2)
.HasColumnType("TEXT");
b.Property<decimal>("UnitPrice")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("WarehouseArticleId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("SalesOrderId");
b.HasIndex("WarehouseArticleId");
b.ToTable("SalesOrderLines", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoEvento", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Codice")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int?>("TipoPastoId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("TipoPastoId");
b.ToTable("TipiEvento");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoMateriale", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Codice")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("TipiMateriale");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoOspite", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Codice")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("TipiOspite");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoPasto", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Codice")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("TipiPasto");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoRisorsa", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Codice")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("TipiRisorsa");
});
modelBuilder.Entity("Zentral.Domain.Entities.Training.TrainingRecord", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticoloId")
.HasColumnType("INTEGER");
b.Property<string>("AttestatoUrl")
.HasColumnType("TEXT");
b.Property<int>("ClienteContattoId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime>("DataEsecuzione")
.HasColumnType("TEXT");
b.Property<DateTime?>("DataScadenza")
.HasColumnType("TEXT");
b.Property<string>("Note")
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticoloId");
b.HasIndex("ClienteContattoId");
b.ToTable("TrainingRecords", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.UserDashboardPreference", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("LayoutJson")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("UtenteId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("UtenteId")
.IsUnique();
b.ToTable("UserDashboardPreferences");
});
modelBuilder.Entity("Zentral.Domain.Entities.Utente", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Cognome")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Email")
.HasColumnType("TEXT");
b.Property<string>("Nome")
.HasColumnType("TEXT");
b.Property<string>("Ruolo")
.HasColumnType("TEXT");
b.Property<bool>("SolaLettura")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<string>("Username")
.IsRequired()
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Username")
.IsUnique();
b.ToTable("Utenti");
});
modelBuilder.Entity("Zentral.Domain.Entities.VirtualDataset", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Attivo")
.HasColumnType("INTEGER");
b.Property<string>("Categoria")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("ConfigurationJson")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Descrizione")
.HasColumnType("TEXT");
b.Property<string>("DisplayName")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Icon")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Nome")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Categoria");
b.HasIndex("Nome")
.IsUnique();
b.ToTable("VirtualDatasets");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.ArticleBarcode", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<string>("Barcode")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<bool>("IsPrimary")
.HasColumnType("INTEGER");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("Barcode")
.IsUnique();
b.ToTable("ArticleBarcodes", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.ArticleBatch", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<string>("BatchNumber")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Certifications")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<decimal>("CurrentQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime?>("ExpiryDate")
.HasColumnType("TEXT");
b.Property<decimal>("InitialQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("LastQualityCheckDate")
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<DateTime?>("ProductionDate")
.HasColumnType("TEXT");
b.Property<int?>("QualityStatus")
.HasColumnType("INTEGER");
b.Property<decimal>("ReservedQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("Status")
.HasColumnType("INTEGER");
b.Property<string>("SupplierBatch")
.HasColumnType("TEXT");
b.Property<int?>("SupplierId")
.HasColumnType("INTEGER");
b.Property<decimal?>("UnitCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ExpiryDate");
b.HasIndex("Status");
b.HasIndex("ArticleId", "BatchNumber")
.IsUnique();
b.ToTable("ArticleBatches", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.ArticleSerial", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<string>("Attributes")
.HasColumnType("TEXT");
b.Property<int?>("BatchId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<int?>("CurrentWarehouseId")
.HasColumnType("INTEGER");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int?>("CustomerId")
.HasColumnType("INTEGER");
b.Property<string>("ManufacturerSerial")
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<DateTime?>("ProductionDate")
.HasColumnType("TEXT");
b.Property<string>("SalesReference")
.HasColumnType("TEXT");
b.Property<string>("SerialNumber")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("SoldDate")
.HasColumnType("TEXT");
b.Property<int>("Status")
.HasColumnType("INTEGER");
b.Property<int?>("SupplierId")
.HasColumnType("INTEGER");
b.Property<decimal?>("UnitCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<DateTime?>("WarrantyExpiryDate")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("BatchId");
b.HasIndex("CurrentWarehouseId");
b.HasIndex("Status");
b.HasIndex("ArticleId", "SerialNumber")
.IsUnique();
b.ToTable("ArticleSerials", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.InventoryCount", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int?>("AdjustmentMovementId")
.HasColumnType("INTEGER");
b.Property<int?>("CategoryId")
.HasColumnType("INTEGER");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("ConfirmedBy")
.HasColumnType("TEXT");
b.Property<DateTime?>("ConfirmedDate")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("EndDate")
.HasColumnType("TEXT");
b.Property<DateTime>("InventoryDate")
.HasColumnType("TEXT");
b.Property<decimal?>("NegativeDifferenceValue")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<decimal?>("PositiveDifferenceValue")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("StartDate")
.HasColumnType("TEXT");
b.Property<int>("Status")
.HasColumnType("INTEGER");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int?>("WarehouseId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("AdjustmentMovementId");
b.HasIndex("CategoryId");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("InventoryDate");
b.HasIndex("Status");
b.HasIndex("WarehouseId");
b.ToTable("InventoryCounts", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.InventoryCountLine", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<int?>("BatchId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CountedAt")
.HasColumnType("TEXT");
b.Property<string>("CountedBy")
.HasColumnType("TEXT");
b.Property<decimal?>("CountedQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int>("InventoryCountId")
.HasColumnType("INTEGER");
b.Property<string>("LocationCode")
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<string>("SecondCountBy")
.HasColumnType("TEXT");
b.Property<decimal?>("SecondCountQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("TheoreticalQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal?>("UnitCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("WarehouseId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("BatchId");
b.HasIndex("WarehouseId");
b.HasIndex("InventoryCountId", "ArticleId", "WarehouseId", "BatchId")
.IsUnique();
b.ToTable("InventoryCountLines", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.MovementReason", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.IsRequired()
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<bool>("IsSystem")
.HasColumnType("INTEGER");
b.Property<int>("MovementType")
.HasColumnType("INTEGER");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<bool>("RequiresExternalReference")
.HasColumnType("INTEGER");
b.Property<bool>("RequiresValuation")
.HasColumnType("INTEGER");
b.Property<int>("SortOrder")
.HasColumnType("INTEGER");
b.Property<int>("StockSign")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<bool>("UpdatesAverageCost")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("IsActive");
b.HasIndex("MovementType");
b.ToTable("MovementReasons", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockLevel", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<int?>("BatchId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<DateTime?>("LastInventoryDate")
.HasColumnType("TEXT");
b.Property<DateTime?>("LastMovementDate")
.HasColumnType("TEXT");
b.Property<string>("LocationCode")
.HasColumnType("TEXT");
b.Property<decimal>("OnOrderQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("ReservedQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal?>("StockValue")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal?>("UnitCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("WarehouseId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("BatchId");
b.HasIndex("LocationCode");
b.HasIndex("WarehouseId");
b.HasIndex("ArticleId", "WarehouseId", "BatchId")
.IsUnique();
b.ToTable("StockLevels", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockMovement", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("ConfirmedBy")
.HasColumnType("TEXT");
b.Property<DateTime?>("ConfirmedDate")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int?>("CustomerId")
.HasColumnType("INTEGER");
b.Property<int?>("DestinationWarehouseId")
.HasColumnType("INTEGER");
b.Property<string>("DocumentNumber")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int?>("ExternalDocumentType")
.HasColumnType("INTEGER");
b.Property<string>("ExternalReference")
.HasColumnType("TEXT");
b.Property<DateTime>("MovementDate")
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<int?>("ReasonId")
.HasColumnType("INTEGER");
b.Property<int?>("SourceWarehouseId")
.HasColumnType("INTEGER");
b.Property<int>("Status")
.HasColumnType("INTEGER");
b.Property<int?>("SupplierId")
.HasColumnType("INTEGER");
b.Property<decimal?>("TotalValue")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("DestinationWarehouseId");
b.HasIndex("DocumentNumber")
.IsUnique();
b.HasIndex("ExternalReference");
b.HasIndex("MovementDate");
b.HasIndex("ReasonId");
b.HasIndex("SourceWarehouseId");
b.HasIndex("Status");
b.HasIndex("Type");
b.ToTable("StockMovements", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockMovementLine", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<int?>("BatchId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("DestinationLocationCode")
.HasColumnType("TEXT");
b.Property<string>("ExternalLineReference")
.HasColumnType("TEXT");
b.Property<int>("LineNumber")
.HasColumnType("INTEGER");
b.Property<decimal?>("LineValue")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("MovementId")
.HasColumnType("INTEGER");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int?>("SerialId")
.HasColumnType("INTEGER");
b.Property<string>("SourceLocationCode")
.HasColumnType("TEXT");
b.Property<decimal?>("UnitCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<string>("UnitOfMeasure")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("BatchId");
b.HasIndex("SerialId");
b.HasIndex("MovementId", "LineNumber")
.IsUnique();
b.ToTable("StockMovementLines", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockValuation", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<string>("ClosedBy")
.HasColumnType("TEXT");
b.Property<DateTime?>("ClosedDate")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<decimal>("InboundQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("InboundValue")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<bool>("IsClosed")
.HasColumnType("INTEGER");
b.Property<int>("Method")
.HasColumnType("INTEGER");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<decimal>("OutboundQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("OutboundValue")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("Period")
.HasColumnType("INTEGER");
b.Property<decimal>("Quantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("TotalValue")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("UnitCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<DateTime>("ValuationDate")
.HasColumnType("TEXT");
b.Property<int?>("WarehouseId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("ArticleId");
b.HasIndex("IsClosed");
b.HasIndex("ValuationDate");
b.HasIndex("WarehouseId");
b.HasIndex("Period", "ArticleId", "WarehouseId")
.IsUnique();
b.ToTable("StockValuations", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockValuationLayer", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("ArticleId")
.HasColumnType("INTEGER");
b.Property<int?>("BatchId")
.HasColumnType("INTEGER");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<bool>("IsExhausted")
.HasColumnType("INTEGER");
b.Property<DateTime>("LayerDate")
.HasColumnType("TEXT");
b.Property<decimal>("OriginalQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal>("RemainingQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int?>("SourceMovementId")
.HasColumnType("INTEGER");
b.Property<decimal>("UnitCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int>("WarehouseId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("BatchId");
b.HasIndex("IsExhausted");
b.HasIndex("SourceMovementId");
b.HasIndex("WarehouseId");
b.HasIndex("ArticleId", "WarehouseId", "LayerDate");
b.ToTable("StockValuationLayers", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.WarehouseArticle", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("AlternativeCode")
.HasColumnType("TEXT");
b.Property<string>("Barcode")
.HasColumnType("TEXT");
b.Property<decimal?>("BaseSellingPrice")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int?>("CategoryId")
.HasColumnType("INTEGER");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<decimal?>("Depth")
.HasColumnType("TEXT");
b.Property<string>("Description")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int?>("ExpiryWarningDays")
.HasColumnType("INTEGER");
b.Property<bool>("HasExpiry")
.HasColumnType("INTEGER");
b.Property<decimal?>("Height")
.HasColumnType("TEXT");
b.Property<byte[]>("Image")
.HasColumnType("BLOB");
b.Property<string>("ImageMimeType")
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<bool>("IsBatchManaged")
.HasColumnType("INTEGER");
b.Property<bool>("IsSerialManaged")
.HasColumnType("INTEGER");
b.Property<decimal?>("LastPurchaseCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int?>("LeadTimeDays")
.HasColumnType("INTEGER");
b.Property<string>("ManufacturerCode")
.HasColumnType("TEXT");
b.Property<decimal?>("MaximumStock")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal?>("MinimumStock")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<int?>("ProductGroupId")
.HasColumnType("INTEGER");
b.Property<decimal?>("ReorderPoint")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal?>("ReorderQuantity")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<string>("SecondaryUnitOfMeasure")
.HasColumnType("TEXT");
b.Property<string>("ShortDescription")
.HasColumnType("TEXT");
b.Property<decimal?>("StandardCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<int>("StockManagement")
.HasColumnType("INTEGER");
b.Property<decimal?>("UnitConversionFactor")
.HasPrecision(18, 6)
.HasColumnType("TEXT");
b.Property<string>("UnitOfMeasure")
.IsRequired()
.HasColumnType("TEXT");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.Property<int?>("ValuationMethod")
.HasColumnType("INTEGER");
b.Property<decimal?>("Volume")
.HasPrecision(18, 6)
.HasColumnType("TEXT");
b.Property<decimal?>("Weight")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal?>("WeightedAverageCost")
.HasPrecision(18, 4)
.HasColumnType("TEXT");
b.Property<decimal?>("Width")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Barcode");
b.HasIndex("CategoryId");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("IsActive");
b.ToTable("WarehouseArticles", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.WarehouseArticleCategory", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("AlternativeCode")
.HasColumnType("TEXT");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Color")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<int?>("DefaultValuationMethod")
.HasColumnType("INTEGER");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<string>("FullPath")
.HasColumnType("TEXT");
b.Property<string>("Icon")
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<int>("Level")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<int?>("ParentCategoryId")
.HasColumnType("INTEGER");
b.Property<int>("SortOrder")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("FullPath");
b.HasIndex("ParentCategoryId");
b.ToTable("WarehouseArticleCategories", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.WarehouseLocation", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Address")
.HasColumnType("TEXT");
b.Property<string>("AlternativeCode")
.HasColumnType("TEXT");
b.Property<string>("City")
.HasColumnType("TEXT");
b.Property<string>("Code")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Country")
.HasColumnType("TEXT");
b.Property<DateTime?>("CreatedAt")
.HasColumnType("TEXT");
b.Property<string>("CreatedBy")
.HasColumnType("TEXT");
b.Property<string>("CustomFieldsJson")
.HasColumnType("TEXT");
b.Property<string>("Description")
.HasColumnType("TEXT");
b.Property<bool>("IsActive")
.HasColumnType("INTEGER");
b.Property<bool>("IsDefault")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Notes")
.HasColumnType("TEXT");
b.Property<string>("PostalCode")
.HasColumnType("TEXT");
b.Property<string>("Province")
.HasColumnType("TEXT");
b.Property<int>("SortOrder")
.HasColumnType("INTEGER");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.Property<DateTime?>("UpdatedAt")
.HasColumnType("TEXT");
b.Property<string>("UpdatedBy")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("Code")
.IsUnique();
b.HasIndex("IsActive");
b.HasIndex("IsDefault");
b.ToTable("WarehouseLocations", (string)null);
});
modelBuilder.Entity("Zentral.Domain.Entities.AppSubscription", b =>
{
b.HasOne("Zentral.Domain.Entities.App", "App")
.WithOne("Subscription")
.HasForeignKey("Zentral.Domain.Entities.AppSubscription", "AppId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("App");
});
modelBuilder.Entity("Zentral.Domain.Entities.Articolo", b =>
{
b.HasOne("Zentral.Domain.Entities.CodiceCategoria", "Categoria")
.WithMany("Articoli")
.HasForeignKey("CategoriaId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.TipoMateriale", "TipoMateriale")
.WithMany("Articoli")
.HasForeignKey("TipoMaterialeId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("Categoria");
b.Navigation("TipoMateriale");
});
modelBuilder.Entity("Zentral.Domain.Entities.ClienteContatto", b =>
{
b.HasOne("Zentral.Domain.Entities.Cliente", "Cliente")
.WithMany("Contatti")
.HasForeignKey("ClienteId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Cliente");
});
modelBuilder.Entity("Zentral.Domain.Entities.Evento", b =>
{
b.HasOne("Zentral.Domain.Entities.Cliente", "Cliente")
.WithMany("Eventi")
.HasForeignKey("ClienteId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Location", "Location")
.WithMany("Eventi")
.HasForeignKey("LocationId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.TipoEvento", "TipoEvento")
.WithMany("Eventi")
.HasForeignKey("TipoEventoId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("Cliente");
b.Navigation("Location");
b.Navigation("TipoEvento");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoAcconto", b =>
{
b.HasOne("Zentral.Domain.Entities.Evento", "Evento")
.WithMany("Acconti")
.HasForeignKey("EventoId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Evento");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoAllegato", b =>
{
b.HasOne("Zentral.Domain.Entities.Evento", "Evento")
.WithMany("Allegati")
.HasForeignKey("EventoId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Evento");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoAltroCosto", b =>
{
b.HasOne("Zentral.Domain.Entities.Evento", "Evento")
.WithMany("AltriCosti")
.HasForeignKey("EventoId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Evento");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoDegustazione", b =>
{
b.HasOne("Zentral.Domain.Entities.Evento", "Evento")
.WithMany("Degustazioni")
.HasForeignKey("EventoId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Evento");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoDettaglioOspiti", b =>
{
b.HasOne("Zentral.Domain.Entities.Evento", "Evento")
.WithMany("DettagliOspiti")
.HasForeignKey("EventoId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.TipoOspite", "TipoOspite")
.WithMany("DettagliOspiti")
.HasForeignKey("TipoOspiteId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Evento");
b.Navigation("TipoOspite");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoDettaglioPrelievo", b =>
{
b.HasOne("Zentral.Domain.Entities.Articolo", "Articolo")
.WithMany("DettagliPrelievo")
.HasForeignKey("ArticoloId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Evento", "Evento")
.WithMany("DettagliPrelievo")
.HasForeignKey("EventoId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Articolo");
b.Navigation("Evento");
});
modelBuilder.Entity("Zentral.Domain.Entities.EventoDettaglioRisorsa", b =>
{
b.HasOne("Zentral.Domain.Entities.Evento", "Evento")
.WithMany("DettagliRisorse")
.HasForeignKey("EventoId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Risorsa", "Risorsa")
.WithMany("DettagliRisorse")
.HasForeignKey("RisorsaId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Evento");
b.Navigation("Risorsa");
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Assenza", b =>
{
b.HasOne("Zentral.Domain.Entities.HR.Dipendente", "Dipendente")
.WithMany("Assenze")
.HasForeignKey("DipendenteId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Dipendente");
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Contratto", b =>
{
b.HasOne("Zentral.Domain.Entities.HR.Dipendente", "Dipendente")
.WithMany("Contratti")
.HasForeignKey("DipendenteId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Dipendente");
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Pagamento", b =>
{
b.HasOne("Zentral.Domain.Entities.HR.Dipendente", "Dipendente")
.WithMany("Pagamenti")
.HasForeignKey("DipendenteId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Dipendente");
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Rimborso", b =>
{
b.HasOne("Zentral.Domain.Entities.HR.Dipendente", "Dipendente")
.WithMany("Rimborsi")
.HasForeignKey("DipendenteId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Dipendente");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.BillOfMaterials", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany()
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("Article");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.BillOfMaterialsComponent", b =>
{
b.HasOne("Zentral.Domain.Entities.Production.BillOfMaterials", "BillOfMaterials")
.WithMany("Components")
.HasForeignKey("BillOfMaterialsId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "ComponentArticle")
.WithMany()
.HasForeignKey("ComponentArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("BillOfMaterials");
b.Navigation("ComponentArticle");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.MrpSuggestion", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany()
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Article");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionCycle", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany()
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("Article");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionCyclePhase", b =>
{
b.HasOne("Zentral.Domain.Entities.Production.ProductionCycle", "ProductionCycle")
.WithMany("Phases")
.HasForeignKey("ProductionCycleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Production.WorkCenter", "WorkCenter")
.WithMany()
.HasForeignKey("WorkCenterId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("ProductionCycle");
b.Navigation("WorkCenter");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionOrder", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany()
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Production.ProductionOrder", "ParentProductionOrder")
.WithMany("ChildProductionOrders")
.HasForeignKey("ParentProductionOrderId");
b.Navigation("Article");
b.Navigation("ParentProductionOrder");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionOrderComponent", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany()
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Production.ProductionOrder", "ProductionOrder")
.WithMany("Components")
.HasForeignKey("ProductionOrderId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Article");
b.Navigation("ProductionOrder");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionOrderPhase", b =>
{
b.HasOne("Zentral.Domain.Entities.Production.ProductionOrder", "ProductionOrder")
.WithMany("Phases")
.HasForeignKey("ProductionOrderId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Production.WorkCenter", "WorkCenter")
.WithMany()
.HasForeignKey("WorkCenterId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("ProductionOrder");
b.Navigation("WorkCenter");
});
modelBuilder.Entity("Zentral.Domain.Entities.Purchases.PurchaseOrder", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "DestinationWarehouse")
.WithMany()
.HasForeignKey("DestinationWarehouseId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Purchases.Supplier", "Supplier")
.WithMany("PurchaseOrders")
.HasForeignKey("SupplierId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("DestinationWarehouse");
b.Navigation("Supplier");
});
modelBuilder.Entity("Zentral.Domain.Entities.Purchases.PurchaseOrderLine", b =>
{
b.HasOne("Zentral.Domain.Entities.Purchases.PurchaseOrder", "PurchaseOrder")
.WithMany("Lines")
.HasForeignKey("PurchaseOrderId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "WarehouseArticle")
.WithMany()
.HasForeignKey("WarehouseArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("PurchaseOrder");
b.Navigation("WarehouseArticle");
});
modelBuilder.Entity("Zentral.Domain.Entities.Risorsa", b =>
{
b.HasOne("Zentral.Domain.Entities.TipoRisorsa", "TipoRisorsa")
.WithMany("Risorse")
.HasForeignKey("TipoRisorsaId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("TipoRisorsa");
});
modelBuilder.Entity("Zentral.Domain.Entities.Sales.SalesOrder", b =>
{
b.HasOne("Zentral.Domain.Entities.Cliente", "Customer")
.WithMany("SalesOrders")
.HasForeignKey("CustomerId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("Customer");
});
modelBuilder.Entity("Zentral.Domain.Entities.Sales.SalesOrderLine", b =>
{
b.HasOne("Zentral.Domain.Entities.Sales.SalesOrder", "SalesOrder")
.WithMany("Lines")
.HasForeignKey("SalesOrderId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "WarehouseArticle")
.WithMany()
.HasForeignKey("WarehouseArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("SalesOrder");
b.Navigation("WarehouseArticle");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoEvento", b =>
{
b.HasOne("Zentral.Domain.Entities.TipoPasto", "TipoPasto")
.WithMany("TipiEvento")
.HasForeignKey("TipoPastoId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("TipoPasto");
});
modelBuilder.Entity("Zentral.Domain.Entities.Training.TrainingRecord", b =>
{
b.HasOne("Zentral.Domain.Entities.Articolo", "Articolo")
.WithMany()
.HasForeignKey("ArticoloId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.ClienteContatto", "ClienteContatto")
.WithMany()
.HasForeignKey("ClienteContattoId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Articolo");
b.Navigation("ClienteContatto");
});
modelBuilder.Entity("Zentral.Domain.Entities.UserDashboardPreference", b =>
{
b.HasOne("Zentral.Domain.Entities.Utente", "Utente")
.WithOne()
.HasForeignKey("Zentral.Domain.Entities.UserDashboardPreference", "UtenteId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Utente");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.ArticleBarcode", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany("Barcodes")
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Article");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.ArticleBatch", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany("Batches")
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Article");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.ArticleSerial", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany("Serials")
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.ArticleBatch", "Batch")
.WithMany("Serials")
.HasForeignKey("BatchId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "CurrentWarehouse")
.WithMany()
.HasForeignKey("CurrentWarehouseId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("Article");
b.Navigation("Batch");
b.Navigation("CurrentWarehouse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.InventoryCount", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.StockMovement", "AdjustmentMovement")
.WithMany()
.HasForeignKey("AdjustmentMovementId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticleCategory", "Category")
.WithMany()
.HasForeignKey("CategoryId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "Warehouse")
.WithMany()
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("AdjustmentMovement");
b.Navigation("Category");
b.Navigation("Warehouse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.InventoryCountLine", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany()
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.ArticleBatch", "Batch")
.WithMany()
.HasForeignKey("BatchId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.InventoryCount", "InventoryCount")
.WithMany("Lines")
.HasForeignKey("InventoryCountId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "Warehouse")
.WithMany()
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.Navigation("Article");
b.Navigation("Batch");
b.Navigation("InventoryCount");
b.Navigation("Warehouse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockLevel", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany("StockLevels")
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.ArticleBatch", "Batch")
.WithMany("StockLevels")
.HasForeignKey("BatchId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "Warehouse")
.WithMany("StockLevels")
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Article");
b.Navigation("Batch");
b.Navigation("Warehouse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockMovement", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "DestinationWarehouse")
.WithMany("DestinationMovements")
.HasForeignKey("DestinationWarehouseId")
.OnDelete(DeleteBehavior.Restrict);
b.HasOne("Zentral.Domain.Entities.Warehouse.MovementReason", "Reason")
.WithMany("Movements")
.HasForeignKey("ReasonId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "SourceWarehouse")
.WithMany("SourceMovements")
.HasForeignKey("SourceWarehouseId")
.OnDelete(DeleteBehavior.Restrict);
b.Navigation("DestinationWarehouse");
b.Navigation("Reason");
b.Navigation("SourceWarehouse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockMovementLine", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany("MovementLines")
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Restrict)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.ArticleBatch", "Batch")
.WithMany("MovementLines")
.HasForeignKey("BatchId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.StockMovement", "Movement")
.WithMany("Lines")
.HasForeignKey("MovementId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.ArticleSerial", "Serial")
.WithMany("MovementLines")
.HasForeignKey("SerialId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("Article");
b.Navigation("Batch");
b.Navigation("Movement");
b.Navigation("Serial");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockValuation", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany()
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "Warehouse")
.WithMany()
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("Article");
b.Navigation("Warehouse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockValuationLayer", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticle", "Article")
.WithMany()
.HasForeignKey("ArticleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Zentral.Domain.Entities.Warehouse.ArticleBatch", "Batch")
.WithMany()
.HasForeignKey("BatchId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.StockMovement", "SourceMovement")
.WithMany()
.HasForeignKey("SourceMovementId")
.OnDelete(DeleteBehavior.SetNull);
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseLocation", "Warehouse")
.WithMany()
.HasForeignKey("WarehouseId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Article");
b.Navigation("Batch");
b.Navigation("SourceMovement");
b.Navigation("Warehouse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.WarehouseArticle", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticleCategory", "Category")
.WithMany("Articles")
.HasForeignKey("CategoryId")
.OnDelete(DeleteBehavior.SetNull);
b.Navigation("Category");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.WarehouseArticleCategory", b =>
{
b.HasOne("Zentral.Domain.Entities.Warehouse.WarehouseArticleCategory", "ParentCategory")
.WithMany("ChildCategories")
.HasForeignKey("ParentCategoryId")
.OnDelete(DeleteBehavior.Restrict);
b.Navigation("ParentCategory");
});
modelBuilder.Entity("Zentral.Domain.Entities.App", b =>
{
b.Navigation("Subscription");
});
modelBuilder.Entity("Zentral.Domain.Entities.Articolo", b =>
{
b.Navigation("DettagliPrelievo");
});
modelBuilder.Entity("Zentral.Domain.Entities.Cliente", b =>
{
b.Navigation("Contatti");
b.Navigation("Eventi");
b.Navigation("SalesOrders");
});
modelBuilder.Entity("Zentral.Domain.Entities.CodiceCategoria", b =>
{
b.Navigation("Articoli");
});
modelBuilder.Entity("Zentral.Domain.Entities.Evento", b =>
{
b.Navigation("Acconti");
b.Navigation("Allegati");
b.Navigation("AltriCosti");
b.Navigation("Degustazioni");
b.Navigation("DettagliOspiti");
b.Navigation("DettagliPrelievo");
b.Navigation("DettagliRisorse");
});
modelBuilder.Entity("Zentral.Domain.Entities.HR.Dipendente", b =>
{
b.Navigation("Assenze");
b.Navigation("Contratti");
b.Navigation("Pagamenti");
b.Navigation("Rimborsi");
});
modelBuilder.Entity("Zentral.Domain.Entities.Location", b =>
{
b.Navigation("Eventi");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.BillOfMaterials", b =>
{
b.Navigation("Components");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionCycle", b =>
{
b.Navigation("Phases");
});
modelBuilder.Entity("Zentral.Domain.Entities.Production.ProductionOrder", b =>
{
b.Navigation("ChildProductionOrders");
b.Navigation("Components");
b.Navigation("Phases");
});
modelBuilder.Entity("Zentral.Domain.Entities.Purchases.PurchaseOrder", b =>
{
b.Navigation("Lines");
});
modelBuilder.Entity("Zentral.Domain.Entities.Purchases.Supplier", b =>
{
b.Navigation("PurchaseOrders");
});
modelBuilder.Entity("Zentral.Domain.Entities.Risorsa", b =>
{
b.Navigation("DettagliRisorse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Sales.SalesOrder", b =>
{
b.Navigation("Lines");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoEvento", b =>
{
b.Navigation("Eventi");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoMateriale", b =>
{
b.Navigation("Articoli");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoOspite", b =>
{
b.Navigation("DettagliOspiti");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoPasto", b =>
{
b.Navigation("TipiEvento");
});
modelBuilder.Entity("Zentral.Domain.Entities.TipoRisorsa", b =>
{
b.Navigation("Risorse");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.ArticleBatch", b =>
{
b.Navigation("MovementLines");
b.Navigation("Serials");
b.Navigation("StockLevels");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.ArticleSerial", b =>
{
b.Navigation("MovementLines");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.InventoryCount", b =>
{
b.Navigation("Lines");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.MovementReason", b =>
{
b.Navigation("Movements");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.StockMovement", b =>
{
b.Navigation("Lines");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.WarehouseArticle", b =>
{
b.Navigation("Barcodes");
b.Navigation("Batches");
b.Navigation("MovementLines");
b.Navigation("Serials");
b.Navigation("StockLevels");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.WarehouseArticleCategory", b =>
{
b.Navigation("Articles");
b.Navigation("ChildCategories");
});
modelBuilder.Entity("Zentral.Domain.Entities.Warehouse.WarehouseLocation", b =>
{
b.Navigation("DestinationMovements");
b.Navigation("SourceMovements");
b.Navigation("StockLevels");
});
#pragma warning restore 612, 618
}
}
}