34 lines
1.1 KiB
C#
34 lines
1.1 KiB
C#
using Microsoft.EntityFrameworkCore;
|
|
using System;
|
|
using TwilioSMSReceiver.Data.Models;
|
|
|
|
namespace TwilioSMSReceiver.Data
|
|
{
|
|
/// <summary>
|
|
/// The database context
|
|
/// </summary>
|
|
public class SMSDbCtx : DbContext
|
|
{
|
|
/// <summary>
|
|
/// The main DB Context base constructor for this database context
|
|
/// </summary>
|
|
/// <param name="options">The usual options for EF Core Database if called outside of a DI Scope</param>
|
|
[Obsolete("Don't call this directly unless you're calling it from a dependency injection container")]
|
|
public SMSDbCtx(DbContextOptions options) : base(options)
|
|
{
|
|
}
|
|
/// <summary>
|
|
/// Received SMS Messages
|
|
/// </summary>
|
|
public DbSet<SMSModel> SMSMessages { get; set; }
|
|
/// <summary>
|
|
/// Received MMS Message data
|
|
/// </summary>
|
|
public DbSet<MMSModel> MMSMessages { get; set; }
|
|
/// <summary>
|
|
/// Teams WebHooks we should be spamming to
|
|
/// </summary>
|
|
public DbSet<MSTeamsWebHook> MSTeamsWebHooks { get; set; }
|
|
}
|
|
}
|