84 lines
2.5 KiB
C#
84 lines
2.5 KiB
C#
// <auto-generated />
|
|
using System;
|
|
using JellyGlass.Repositories;
|
|
using Microsoft.EntityFrameworkCore;
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
|
|
#nullable disable
|
|
|
|
namespace JellyGlassBackend.Migrations
|
|
{
|
|
[DbContext(typeof(DatabaseContext))]
|
|
partial class DatabaseContextModelSnapshot : ModelSnapshot
|
|
{
|
|
protected override void BuildModel(ModelBuilder modelBuilder)
|
|
{
|
|
#pragma warning disable 612, 618
|
|
modelBuilder.HasAnnotation("ProductVersion", "9.0.11");
|
|
|
|
modelBuilder.Entity("JellyGlass.Models.Server", b =>
|
|
{
|
|
b.Property<string>("Url")
|
|
.HasColumnType("TEXT");
|
|
|
|
b.Property<string>("ApiToken")
|
|
.IsRequired()
|
|
.HasColumnType("TEXT");
|
|
|
|
b.Property<string>("Owner")
|
|
.IsRequired()
|
|
.HasColumnType("TEXT");
|
|
|
|
b.HasKey("Url");
|
|
|
|
b.ToTable("Servers");
|
|
});
|
|
|
|
modelBuilder.Entity("JellyGlass.Models.UserLogin", b =>
|
|
{
|
|
b.Property<string>("Username")
|
|
.HasColumnType("TEXT");
|
|
|
|
b.Property<string>("HashedPassword")
|
|
.IsRequired()
|
|
.HasColumnType("TEXT");
|
|
|
|
b.Property<bool>("IsAdmin")
|
|
.HasColumnType("INTEGER");
|
|
|
|
b.HasKey("Username");
|
|
|
|
b.ToTable("Logins");
|
|
});
|
|
|
|
modelBuilder.Entity("JellyGlass.Models.UserSession", b =>
|
|
{
|
|
b.Property<string>("SessionToken")
|
|
.HasColumnType("TEXT");
|
|
|
|
b.Property<DateTime>("ExpiresOn")
|
|
.HasColumnType("TEXT");
|
|
|
|
b.Property<string>("LoginUsername")
|
|
.HasColumnType("TEXT");
|
|
|
|
b.HasKey("SessionToken");
|
|
|
|
b.HasIndex("LoginUsername");
|
|
|
|
b.ToTable("Sessions");
|
|
});
|
|
|
|
modelBuilder.Entity("JellyGlass.Models.UserSession", b =>
|
|
{
|
|
b.HasOne("JellyGlass.Models.UserLogin", "Login")
|
|
.WithMany()
|
|
.HasForeignKey("LoginUsername");
|
|
|
|
b.Navigation("Login");
|
|
});
|
|
#pragma warning restore 612, 618
|
|
}
|
|
}
|
|
}
|