29 lines
803 B
C#
29 lines
803 B
C#
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
namespace ApiPolo.Models.Siet_dbcontext
|
|
{
|
|
/// <summary></summary>
|
|
public class SIET_PRESE_DbContext : DbContext
|
|
{
|
|
/// <summary></summary>
|
|
public DbSet<Prese>? Prese { get; set; }
|
|
|
|
/// <summary></summary>
|
|
public SIET_PRESE_DbContext(DbContextOptions<SIET_PRESE_DbContext> options) : base(options)
|
|
{
|
|
}
|
|
/// <summary></summary>
|
|
protected override void OnModelCreating(ModelBuilder modelBuilder)
|
|
{
|
|
modelBuilder.Entity<Prese>().ToTable("PRESA");
|
|
modelBuilder.Entity<Prese>().HasKey(table => new {
|
|
table.picodazi,
|
|
table.pimpianto,
|
|
table.picodint,
|
|
table.pidatman
|
|
});
|
|
}
|
|
}
|
|
}
|