using Microsoft.EntityFrameworkCore; using Microsoft.eShopWeb.ApplicationCore.Entities; using Microsoft.eShopWeb.ApplicationCore.Entities.BasketAggregate; using Microsoft.eShopWeb.ApplicationCore.Entities.OrderAggregate; using System.Reflection; namespace Microsoft.eShopWeb.Infrastructure.Data { public class CatalogContext : DbContext { public CatalogContext(DbContextOptions options) : base(options) { } public DbSet Baskets { get; set; } public DbSet CatalogItems { get; set; } public DbSet CatalogBrands { get; set; } public DbSet CatalogTypes { get; set; } public DbSet Orders { get; set; } public DbSet OrderItems { get; set; } public DbSet BasketItems { get; set; } protected override void OnModelCreating(ModelBuilder builder) { base.OnModelCreating(builder); builder.ApplyConfigurationsFromAssembly(Assembly.GetExecutingAssembly()); } } }