songrequests_blazor/songrequests_blazor/Migrations/20240626183259_AddSessionName.Designer.cs
2024-06-26 20:35:18 +02:00

560 lines
20 KiB
C#

// <auto-generated />
using System;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using songrequests_blazor.Data;
#nullable disable
namespace songrequests_blazor.Migrations
{
[DbContext(typeof(LocalDbContext))]
[Migration("20240626183259_AddSessionName")]
partial class AddSessionName
{
/// <inheritdoc />
protected override void BuildTargetModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "8.0.5");
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRole", b =>
{
b.Property<string>("Id")
.HasColumnType("TEXT");
b.Property<string>("ConcurrencyStamp")
.IsConcurrencyToken()
.HasColumnType("TEXT");
b.Property<string>("Name")
.HasMaxLength(256)
.HasColumnType("TEXT");
b.Property<string>("NormalizedName")
.HasMaxLength(256)
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("NormalizedName")
.IsUnique()
.HasDatabaseName("RoleNameIndex");
b.ToTable("AspNetRoles", (string)null);
b.HasData(
new
{
Id = "fc985a25-19ce-48ed-8443-c845f550960a",
Name = "Administrator",
NormalizedName = "ADMINISTRATOR"
});
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("ClaimType")
.HasColumnType("TEXT");
b.Property<string>("ClaimValue")
.HasColumnType("TEXT");
b.Property<string>("RoleId")
.IsRequired()
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("RoleId");
b.ToTable("AspNetRoleClaims", (string)null);
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUser", b =>
{
b.Property<string>("Id")
.HasColumnType("TEXT");
b.Property<int>("AccessFailedCount")
.HasColumnType("INTEGER");
b.Property<string>("ConcurrencyStamp")
.IsConcurrencyToken()
.HasColumnType("TEXT");
b.Property<string>("Discriminator")
.IsRequired()
.HasMaxLength(13)
.HasColumnType("TEXT");
b.Property<string>("Email")
.HasMaxLength(256)
.HasColumnType("TEXT");
b.Property<bool>("EmailConfirmed")
.HasColumnType("INTEGER");
b.Property<bool>("LockoutEnabled")
.HasColumnType("INTEGER");
b.Property<DateTimeOffset?>("LockoutEnd")
.HasColumnType("TEXT");
b.Property<string>("NormalizedEmail")
.HasMaxLength(256)
.HasColumnType("TEXT");
b.Property<string>("NormalizedUserName")
.HasMaxLength(256)
.HasColumnType("TEXT");
b.Property<string>("PasswordHash")
.HasColumnType("TEXT");
b.Property<string>("PhoneNumber")
.HasColumnType("TEXT");
b.Property<bool>("PhoneNumberConfirmed")
.HasColumnType("INTEGER");
b.Property<string>("SecurityStamp")
.HasColumnType("TEXT");
b.Property<bool>("TwoFactorEnabled")
.HasColumnType("INTEGER");
b.Property<string>("UserName")
.HasMaxLength(256)
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("NormalizedEmail")
.HasDatabaseName("EmailIndex");
b.HasIndex("NormalizedUserName")
.IsUnique()
.HasDatabaseName("UserNameIndex");
b.ToTable("AspNetUsers", (string)null);
b.HasDiscriminator<string>("Discriminator").HasValue("IdentityUser");
b.UseTphMappingStrategy();
b.HasData(
new
{
Id = "5c2511d0-6a08-4950-babd-d107996749ba",
AccessFailedCount = 0,
ConcurrencyStamp = "7d7fc619-fde4-408c-8816-f4ed5f68a60e",
Email = "admin@admin.com",
EmailConfirmed = false,
LockoutEnabled = false,
NormalizedEmail = "ADMIN@ADMIN.COM",
NormalizedUserName = "ADMIN@ADMIN.COM",
PasswordHash = "AQAAAAIAAYagAAAAECVwoHKYEXKRa9Sp3UeNNeVSEZOUkCEVkYcF09ZOVlLm9VeDEoX8M9NzwegIk0EWrw==",
PhoneNumberConfirmed = false,
SecurityStamp = "10af871c-53d6-4dfc-9e69-5d3a97d8a016",
TwoFactorEnabled = false,
UserName = "admin@admin.com"
});
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("ClaimType")
.HasColumnType("TEXT");
b.Property<string>("ClaimValue")
.HasColumnType("TEXT");
b.Property<string>("UserId")
.IsRequired()
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("UserId");
b.ToTable("AspNetUserClaims", (string)null);
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
{
b.Property<string>("LoginProvider")
.HasColumnType("TEXT");
b.Property<string>("ProviderKey")
.HasColumnType("TEXT");
b.Property<string>("ProviderDisplayName")
.HasColumnType("TEXT");
b.Property<string>("UserId")
.IsRequired()
.HasColumnType("TEXT");
b.HasKey("LoginProvider", "ProviderKey");
b.HasIndex("UserId");
b.ToTable("AspNetUserLogins", (string)null);
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
{
b.Property<string>("UserId")
.HasColumnType("TEXT");
b.Property<string>("RoleId")
.HasColumnType("TEXT");
b.HasKey("UserId", "RoleId");
b.HasIndex("RoleId");
b.ToTable("AspNetUserRoles", (string)null);
b.HasData(
new
{
UserId = "5c2511d0-6a08-4950-babd-d107996749ba",
RoleId = "fc985a25-19ce-48ed-8443-c845f550960a"
});
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
{
b.Property<string>("UserId")
.HasColumnType("TEXT");
b.Property<string>("LoginProvider")
.HasColumnType("TEXT");
b.Property<string>("Name")
.HasColumnType("TEXT");
b.Property<string>("Value")
.HasColumnType("TEXT");
b.HasKey("UserId", "LoginProvider", "Name");
b.ToTable("AspNetUserTokens", (string)null);
});
modelBuilder.Entity("QueuedSongs_UserVotes", b =>
{
b.Property<string>("UserVotesId")
.HasColumnType("TEXT");
b.Property<int>("VotedSongsId")
.HasColumnType("INTEGER");
b.HasKey("UserVotesId", "VotedSongsId");
b.HasIndex("VotedSongsId");
b.ToTable("QueuedSongs_UserVotes");
});
modelBuilder.Entity("Sessions_Libraries", b =>
{
b.Property<int>("EnabledLibrariesId")
.HasColumnType("INTEGER");
b.Property<int>("UsedInSessionsId")
.HasColumnType("INTEGER");
b.HasKey("EnabledLibrariesId", "UsedInSessionsId");
b.HasIndex("UsedInSessionsId");
b.ToTable("Sessions_Libraries");
});
modelBuilder.Entity("songrequests_blazor.Data.Library", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("ScanPaths")
.HasColumnType("TEXT");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.ToTable("Libraries");
});
modelBuilder.Entity("songrequests_blazor.Data.QueuedSong", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime>("Added")
.HasColumnType("TEXT");
b.Property<string>("AddedBy_User_ID")
.HasColumnType("TEXT");
b.Property<DateTime?>("Played")
.HasColumnType("TEXT");
b.Property<int>("Position")
.HasColumnType("INTEGER");
b.Property<int>("Session_ID")
.HasColumnType("INTEGER");
b.Property<int>("Song_ID")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("AddedBy_User_ID");
b.HasIndex("Session_ID");
b.HasIndex("Song_ID");
b.ToTable("QueuedSongs");
});
modelBuilder.Entity("songrequests_blazor.Data.Session", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<bool>("Active")
.HasColumnType("INTEGER");
b.Property<DateTime>("Created")
.HasColumnType("TEXT");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("SessionCode")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("Sessions");
});
modelBuilder.Entity("songrequests_blazor.Data.Song", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Album")
.HasColumnType("TEXT");
b.Property<string>("Artist")
.HasColumnType("TEXT");
b.Property<string>("Genre")
.HasColumnType("TEXT");
b.Property<TimeSpan>("Length")
.HasColumnType("TEXT");
b.Property<int>("Library_ID")
.HasColumnType("INTEGER");
b.Property<int>("RequestCount")
.HasColumnType("INTEGER");
b.Property<string>("Title")
.IsRequired()
.HasColumnType("TEXT");
b.Property<string>("Uri")
.IsRequired()
.HasColumnType("TEXT");
b.Property<int?>("Year")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("Library_ID");
b.ToTable("Songs");
});
modelBuilder.Entity("songrequests_blazor.Data.User", b =>
{
b.HasBaseType("Microsoft.AspNetCore.Identity.IdentityUser");
b.HasDiscriminator().HasValue("User");
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
{
b.HasOne("Microsoft.AspNetCore.Identity.IdentityRole", null)
.WithMany()
.HasForeignKey("RoleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
{
b.HasOne("Microsoft.AspNetCore.Identity.IdentityUser", null)
.WithMany()
.HasForeignKey("UserId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
{
b.HasOne("Microsoft.AspNetCore.Identity.IdentityUser", null)
.WithMany()
.HasForeignKey("UserId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
{
b.HasOne("Microsoft.AspNetCore.Identity.IdentityRole", null)
.WithMany()
.HasForeignKey("RoleId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("Microsoft.AspNetCore.Identity.IdentityUser", null)
.WithMany()
.HasForeignKey("UserId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
});
modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
{
b.HasOne("Microsoft.AspNetCore.Identity.IdentityUser", null)
.WithMany()
.HasForeignKey("UserId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
});
modelBuilder.Entity("QueuedSongs_UserVotes", b =>
{
b.HasOne("songrequests_blazor.Data.User", null)
.WithMany()
.HasForeignKey("UserVotesId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("songrequests_blazor.Data.QueuedSong", null)
.WithMany()
.HasForeignKey("VotedSongsId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
});
modelBuilder.Entity("Sessions_Libraries", b =>
{
b.HasOne("songrequests_blazor.Data.Library", null)
.WithMany()
.HasForeignKey("EnabledLibrariesId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("songrequests_blazor.Data.Session", null)
.WithMany()
.HasForeignKey("UsedInSessionsId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
});
modelBuilder.Entity("songrequests_blazor.Data.QueuedSong", b =>
{
b.HasOne("songrequests_blazor.Data.User", "AdddedBy")
.WithMany("AddedSongs")
.HasForeignKey("AddedBy_User_ID")
.HasConstraintName("FK_user_addedsongs");
b.HasOne("songrequests_blazor.Data.Session", "Session")
.WithMany("QueuedSongs")
.HasForeignKey("Session_ID")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired()
.HasConstraintName("FK_Session_QueuedSongs");
b.HasOne("songrequests_blazor.Data.Song", "Song")
.WithMany("Queued")
.HasForeignKey("Song_ID")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired()
.HasConstraintName("FK_queuedsongs_song");
b.Navigation("AdddedBy");
b.Navigation("Session");
b.Navigation("Song");
});
modelBuilder.Entity("songrequests_blazor.Data.Song", b =>
{
b.HasOne("songrequests_blazor.Data.Library", "Library")
.WithMany("Songs")
.HasForeignKey("Library_ID")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired()
.HasConstraintName("FK_library_songs");
b.Navigation("Library");
});
modelBuilder.Entity("songrequests_blazor.Data.Library", b =>
{
b.Navigation("Songs");
});
modelBuilder.Entity("songrequests_blazor.Data.Session", b =>
{
b.Navigation("QueuedSongs");
});
modelBuilder.Entity("songrequests_blazor.Data.Song", b =>
{
b.Navigation("Queued");
});
modelBuilder.Entity("songrequests_blazor.Data.User", b =>
{
b.Navigation("AddedSongs");
});
#pragma warning restore 612, 618
}
}
}