mirror of
https://github.com/yawaflua/yaflay.ru.git
synced 2026-02-04 10:54:12 +02:00
22 lines
644 B
C#
22 lines
644 B
C#
using Microsoft.EntityFrameworkCore;
|
|
using yaflay.ru.Models.Tables;
|
|
|
|
namespace yaflay.ru.Models
|
|
{
|
|
public class AppDbContext : DbContext
|
|
{
|
|
|
|
public AppDbContext(DbContextOptions<AppDbContext> options) : base(options) {
|
|
AppContext.SetSwitch("Npgsql.EnableLegacyTimestampBehavior", true);
|
|
}
|
|
|
|
public DbSet<Blogs> Blogs { get; set; }
|
|
public DbSet<Comments> Comments { get; set; }
|
|
public DbSet<Redirects> Redirects { get; set; }
|
|
protected override void OnModelCreating(ModelBuilder modelBuilder)
|
|
{
|
|
base.OnModelCreating(modelBuilder);
|
|
}
|
|
}
|
|
}
|