22 lines
619 B
C#
22 lines
619 B
C#
using Liber_Incantamentum.Domain.Entities;
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
namespace Liber_Incantamentum.Infrastructure.Persistence
|
|
{
|
|
public class AppDbContext : DbContext
|
|
{
|
|
public AppDbContext(DbContextOptions options) : base(options)
|
|
{
|
|
}
|
|
public DbSet<Mage> Mages { get; set; }
|
|
public DbSet<Spell> Spells { get; set; }
|
|
|
|
protected override void OnModelCreating(ModelBuilder modelBuilder)
|
|
{
|
|
modelBuilder.ApplyConfigurationsFromAssembly(typeof(AppDbContext).Assembly);
|
|
base.OnModelCreating(modelBuilder);
|
|
}
|
|
}
|
|
|
|
}
|