ApiManutenzioni/ApiPolo/Models/Gitoga_dbcontext/GITSR_COMMESSE_TABLE_DbContext.cs

26 lines
770 B
C#

using Microsoft.EntityFrameworkCore;
namespace ApiPolo.Models.Gitoga_dbcontext
{
/// <summary></summary>
public class GITSR_COMMESSE_TABLE_DbContext : DbContext
{
/// <summary></summary>
public DbSet<CommessaDesc>? Commdesc { get; set; }
/// <summary></summary>
public GITSR_COMMESSE_TABLE_DbContext(DbContextOptions<GITSR_COMMESSE_TABLE_DbContext> options) : base(options)
{
}
/// <summary></summary>
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
modelBuilder.Entity<CommessaDesc>().ToTable("GITSRLAV_MAST");
modelBuilder.Entity<CommessaDesc>().HasKey(table => new {
table.laserial
});
}
}
}