Files
PLib/src/PLib.Infrastructure/Persistence/LibraryDbContext.cs
T

16 lines
487 B
C#

using Microsoft.EntityFrameworkCore;
using PLib.Domain.Videos;
namespace PLib.Infrastructure.Persistence;
public sealed class LibraryDbContext(DbContextOptions<LibraryDbContext> options) : DbContext(options)
{
public DbSet<VideoItem> Videos => Set<VideoItem>();
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
modelBuilder.ApplyConfigurationsFromAssembly(typeof(LibraryDbContext).Assembly);
base.OnModelCreating(modelBuilder);
}
}