23 lines
719 B
C#
23 lines
719 B
C#
using Microsoft.EntityFrameworkCore;
|
|
using Nashel.Modules.Collaboration.Domain.Entities;
|
|
|
|
namespace Nashel.Modules.Collaboration.Infrastructure.Persistence
|
|
{
|
|
public class CollaborationDbContext : DbContext
|
|
{
|
|
public DbSet<Contract> Contracts { get; set; }
|
|
|
|
public CollaborationDbContext(DbContextOptions<CollaborationDbContext> options)
|
|
: base(options)
|
|
{
|
|
}
|
|
|
|
protected override void OnModelCreating(ModelBuilder modelBuilder)
|
|
{
|
|
modelBuilder.HasDefaultSchema("collaboration");
|
|
modelBuilder.ApplyConfigurationsFromAssembly(typeof(CollaborationDbContext).Assembly);
|
|
base.OnModelCreating(modelBuilder);
|
|
}
|
|
}
|
|
}
|