2024-01-08 23:21:04 +03:00
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
using Mirea.Api.DataAccess.Domain.Schedule;
|
2024-05-30 20:12:36 +03:00
|
|
|
|
using Mirea.Api.DataAccess.Persistence.Common;
|
|
|
|
|
using System.Reflection;
|
2024-01-08 23:21:04 +03:00
|
|
|
|
|
|
|
|
|
namespace Mirea.Api.DataAccess.Persistence;
|
|
|
|
|
|
2024-05-30 20:12:36 +03:00
|
|
|
|
public class UberDbContext(DbContextOptions<UberDbContext> options) : BaseDbContext<UberDbContext>(options)
|
2024-01-08 23:21:04 +03:00
|
|
|
|
{
|
2024-01-26 07:43:27 +03:00
|
|
|
|
public DbSet<Campus> Campuses { get; set; } = null!;
|
|
|
|
|
public DbSet<Discipline> Disciplines { get; set; } = null!;
|
|
|
|
|
public DbSet<Faculty> Faculties { get; set; } = null!;
|
2024-01-08 23:21:04 +03:00
|
|
|
|
public DbSet<Group> Groups { get; set; } = null!;
|
|
|
|
|
public DbSet<LectureHall> LectureHalls { get; set; } = null!;
|
2024-01-26 07:43:27 +03:00
|
|
|
|
public DbSet<LessonAssociation> LessonAssociations { get; set; } = null!;
|
2024-01-08 23:21:04 +03:00
|
|
|
|
public DbSet<Lesson> Lessons { get; set; } = null!;
|
|
|
|
|
public DbSet<Professor> Professors { get; set; } = null!;
|
|
|
|
|
public DbSet<TypeOfOccupation> TypeOfOccupations { get; set; } = null!;
|
2024-05-19 11:52:56 +03:00
|
|
|
|
public DbSet<SpecificWeek> SpecificWeeks { get; set; } = null!;
|
2024-01-08 23:21:04 +03:00
|
|
|
|
|
|
|
|
|
protected override void OnModelCreating(ModelBuilder modelBuilder)
|
|
|
|
|
{
|
2024-05-30 20:12:36 +03:00
|
|
|
|
modelBuilder.ApplyConfigurationsFromAssembly(Assembly.GetExecutingAssembly());
|
2024-01-08 23:21:04 +03:00
|
|
|
|
base.OnModelCreating(modelBuilder);
|
|
|
|
|
}
|
|
|
|
|
}
|