You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Dotnet-WebAPI/AppContext/AppContext.cs

20 lines
533 B

using AppContext.Entities;
using Microsoft.EntityFrameworkCore;
namespace AppContext;
public class AppContext(DbContextOptions<AppContext> options) : DbContext(options)
{
public DbSet<UserEntity> Users { get; }
public DbSet<TacticEntity> Tactics { get; }
public DbSet<TeamEntity> Teams { get; }
public DbSet<MemberEntity> Members { get; }
public AppContext() : this(
new DbContextOptionsBuilder<AppContext>()
.UseSqlite("Data Source=database.db")
.Options
)
{
}
}