28 lines
841 B
C#
28 lines
841 B
C#
using Microsoft.EntityFrameworkCore;
|
|
|
|
namespace ApiPolo.Models.Marrocco_dbcontext
|
|
{
|
|
/// <summary></summary>
|
|
public class MARRO_NOTIFICHEDbContext : DbContext
|
|
{
|
|
/// <summary></summary>
|
|
public DbSet<Notifiche>? Notif { get; set; }
|
|
|
|
/// <summary></summary>
|
|
public MARRO_NOTIFICHEDbContext(DbContextOptions<MARRO_NOTIFICHEDbContext> options) : base(options)
|
|
{
|
|
}
|
|
|
|
/// <summary></summary>
|
|
protected override void OnModelCreating(ModelBuilder modelBuilder)
|
|
{
|
|
//modelBuilder.Entity<Notifiche>().ToView("API_NOTIFICHE");
|
|
modelBuilder.Entity<Notifiche>().ToTable("PINOTIFI");
|
|
modelBuilder.Entity<Notifiche>().HasKey(table => new {
|
|
table.picodazi,
|
|
table.piserial
|
|
});
|
|
}
|
|
}
|
|
}
|