Feat Widgets
This commit is contained in:
		| @@ -19,6 +19,7 @@ public class EleccionesDbContext(DbContextOptions<EleccionesDbContext> options) | ||||
|     public DbSet<Configuracion> Configuraciones { get; set; } | ||||
|     public DbSet<Bancada> Bancadas { get; set; } | ||||
|     public DbSet<OcupanteBanca> OcupantesBancas { get; set; } | ||||
|     public DbSet<LogoAgrupacionCategoria> LogosAgrupacionesCategorias { get; set; } | ||||
|  | ||||
|     protected override void OnModelCreating(ModelBuilder modelBuilder) | ||||
|     { | ||||
| @@ -75,5 +76,9 @@ public class EleccionesDbContext(DbContextOptions<EleccionesDbContext> options) | ||||
|             // Opcional: puede definir un índice | ||||
|             entity.HasIndex(o => o.BancadaId).IsUnique(); | ||||
|         }); | ||||
|         modelBuilder.Entity<LogoAgrupacionCategoria>(entity => | ||||
|         { | ||||
|             entity.HasIndex(l => new { l.AgrupacionPoliticaId, l.CategoriaId }).IsUnique(); | ||||
|         }); | ||||
|     } | ||||
| } | ||||
		Reference in New Issue
	
	Block a user