No release yet
This commit is contained in:
49
src/isnd/Data/ApplicationDbContext.cs
Normal file
49
src/isnd/Data/ApplicationDbContext.cs
Normal file
@ -0,0 +1,49 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using Microsoft.AspNetCore.Identity;
|
||||
using Microsoft.AspNetCore.Identity.EntityFrameworkCore;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using isnd.Data;
|
||||
using isnd.Data.ApiKeys;
|
||||
using isnd.Data.Packages;
|
||||
|
||||
namespace isnd.Data
|
||||
{
|
||||
/// <summary>
|
||||
/// Application Db Context
|
||||
/// </summary>
|
||||
public class ApplicationDbContext : IdentityDbContext<ApplicationUser>
|
||||
{
|
||||
/// <summary>
|
||||
/// db context ctor
|
||||
/// </summary>
|
||||
/// <param name="options"></param>
|
||||
public ApplicationDbContext(DbContextOptions<ApplicationDbContext> options)
|
||||
: base(options) { }
|
||||
|
||||
/// <summary>
|
||||
/// User API keys
|
||||
/// </summary>
|
||||
/// <value></value>
|
||||
public DbSet<ApiKey> ApiKeys { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Packages
|
||||
/// </summary>
|
||||
/// <value></value>
|
||||
public DbSet<Package> Packages { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Package Versions
|
||||
/// </summary>
|
||||
/// <value></value>
|
||||
public DbSet<PackageVersion> PackageVersions { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Commits
|
||||
/// </summary>
|
||||
/// <value></value>
|
||||
public DbSet<Commit> Commits { get; set; }
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user