jellyfin/Jellyfin.Server.Implementations/Migrations/JellyfinDbModelSnapshot.cs

400 lines
14 KiB
C#
Raw Normal View History

// <auto-generated />
2020-05-02 15:32:22 -07:00
using System;
2020-05-15 14:24:01 -07:00
using Jellyfin.Server.Implementations;
2020-05-02 15:32:22 -07:00
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
2020-05-15 14:24:01 -07:00
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
2020-05-02 15:32:22 -07:00
namespace Jellyfin.Server.Implementations.Migrations
{
[DbContext(typeof(JellyfinDb))]
partial class JellyfinDbModelSnapshot : ModelSnapshot
{
protected override void BuildModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasDefaultSchema("jellyfin")
2020-06-30 18:44:41 -07:00
.HasAnnotation("ProductVersion", "3.1.5");
2020-05-02 15:32:22 -07:00
2020-05-15 14:24:01 -07:00
modelBuilder.Entity("Jellyfin.Data.Entities.AccessSchedule", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("DayOfWeek")
.HasColumnType("INTEGER");
b.Property<double>("EndHour")
.HasColumnType("REAL");
b.Property<double>("StartHour")
.HasColumnType("REAL");
b.Property<Guid>("UserId")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("UserId");
2020-06-13 08:56:18 -07:00
b.ToTable("AccessSchedules");
2020-05-15 14:24:01 -07:00
});
2020-05-02 15:32:22 -07:00
modelBuilder.Entity("Jellyfin.Data.Entities.ActivityLog", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime>("DateCreated")
.HasColumnType("TEXT");
b.Property<string>("ItemId")
.HasColumnType("TEXT")
.HasMaxLength(256);
b.Property<int>("LogSeverity")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("TEXT")
.HasMaxLength(512);
b.Property<string>("Overview")
.HasColumnType("TEXT")
.HasMaxLength(512);
b.Property<uint>("RowVersion")
.IsConcurrencyToken()
.HasColumnType("INTEGER");
b.Property<string>("ShortOverview")
.HasColumnType("TEXT")
.HasMaxLength(512);
b.Property<string>("Type")
.IsRequired()
.HasColumnType("TEXT")
.HasMaxLength(256);
b.Property<Guid>("UserId")
.HasColumnType("TEXT");
b.HasKey("Id");
2020-05-14 14:13:45 -07:00
b.ToTable("ActivityLogs");
2020-05-02 15:32:22 -07:00
});
2020-05-04 13:00:41 -07:00
2020-06-30 18:44:41 -07:00
modelBuilder.Entity("Jellyfin.Data.Entities.DisplayPreferences", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Client")
.IsRequired()
.HasColumnType("TEXT")
.HasMaxLength(64);
b.Property<int?>("IndexBy")
.HasColumnType("INTEGER");
b.Property<Guid?>("ItemId")
.HasColumnType("TEXT");
b.Property<bool>("RememberIndexing")
.HasColumnType("INTEGER");
b.Property<bool>("RememberSorting")
.HasColumnType("INTEGER");
b.Property<int>("ScrollDirection")
.HasColumnType("INTEGER");
b.Property<bool>("ShowBackdrop")
.HasColumnType("INTEGER");
b.Property<bool>("ShowSidebar")
.HasColumnType("INTEGER");
b.Property<string>("SortBy")
.HasColumnType("TEXT");
b.Property<int>("SortOrder")
.HasColumnType("INTEGER");
b.Property<Guid>("UserId")
.HasColumnType("TEXT");
b.Property<int?>("ViewType")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("UserId");
b.ToTable("DisplayPreferences");
});
modelBuilder.Entity("Jellyfin.Data.Entities.HomeSection", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("DisplayPreferencesId")
.HasColumnType("INTEGER");
b.Property<int>("Order")
.HasColumnType("INTEGER");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("DisplayPreferencesId");
b.ToTable("HomeSection");
});
2020-05-15 14:24:01 -07:00
modelBuilder.Entity("Jellyfin.Data.Entities.ImageInfo", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
2020-05-04 13:00:41 -07:00
2020-05-15 14:24:01 -07:00
b.Property<DateTime>("LastModified")
.HasColumnType("TEXT");
b.Property<string>("Path")
.IsRequired()
2020-05-26 18:20:55 -07:00
.HasColumnType("TEXT")
.HasMaxLength(512);
2020-05-15 14:24:01 -07:00
2020-06-13 13:38:17 -07:00
b.Property<Guid?>("UserId")
.HasColumnType("TEXT");
2020-05-15 14:24:01 -07:00
b.HasKey("Id");
2020-06-13 13:38:17 -07:00
b.HasIndex("UserId")
.IsUnique();
2020-06-13 08:56:18 -07:00
b.ToTable("ImageInfos");
2020-05-04 13:00:41 -07:00
});
modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("Kind")
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<Guid?>("Permission_Permissions_Guid")
.HasColumnType("TEXT");
2020-05-04 13:00:41 -07:00
b.Property<uint>("RowVersion")
.IsConcurrencyToken()
.HasColumnType("INTEGER");
b.Property<bool>("Value")
.HasColumnType("INTEGER");
b.HasKey("Id");
2020-05-15 14:24:01 -07:00
b.HasIndex("Permission_Permissions_Guid");
2020-05-04 13:00:41 -07:00
2020-05-15 14:24:01 -07:00
b.ToTable("Permissions");
2020-05-04 13:00:41 -07:00
});
modelBuilder.Entity("Jellyfin.Data.Entities.Preference", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("Kind")
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<Guid?>("Preference_Preferences_Guid")
.HasColumnType("TEXT");
2020-05-04 13:00:41 -07:00
b.Property<uint>("RowVersion")
.IsConcurrencyToken()
.HasColumnType("INTEGER");
b.Property<string>("Value")
.IsRequired()
.HasColumnType("TEXT")
.HasMaxLength(65535);
b.HasKey("Id");
2020-05-15 14:24:01 -07:00
b.HasIndex("Preference_Preferences_Guid");
b.ToTable("Preferences");
2020-05-04 13:00:41 -07:00
});
modelBuilder.Entity("Jellyfin.Data.Entities.User", b =>
{
2020-05-15 14:24:01 -07:00
b.Property<Guid>("Id")
2020-05-04 13:00:41 -07:00
.ValueGeneratedOnAdd()
2020-05-15 14:24:01 -07:00
.HasColumnType("TEXT");
2020-05-04 13:00:41 -07:00
b.Property<string>("AudioLanguagePreference")
.HasColumnType("TEXT")
.HasMaxLength(255);
b.Property<string>("AuthenticationProviderId")
.IsRequired()
.HasColumnType("TEXT")
.HasMaxLength(255);
2020-05-15 14:24:01 -07:00
b.Property<bool>("DisplayCollectionsView")
2020-05-04 13:00:41 -07:00
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<bool>("DisplayMissingEpisodes")
2020-05-04 13:00:41 -07:00
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<string>("EasyPassword")
.HasColumnType("TEXT")
.HasMaxLength(65535);
b.Property<bool>("EnableAutoLogin")
2020-05-04 13:00:41 -07:00
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<bool>("EnableLocalPassword")
2020-05-04 13:00:41 -07:00
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<bool>("EnableNextEpisodeAutoPlay")
.HasColumnType("INTEGER");
2020-05-04 13:00:41 -07:00
2020-05-15 14:24:01 -07:00
b.Property<bool>("EnableUserPreferenceAccess")
.HasColumnType("INTEGER");
b.Property<bool>("HidePlayedInLatest")
.HasColumnType("INTEGER");
b.Property<long>("InternalId")
2020-05-04 13:00:41 -07:00
.HasColumnType("INTEGER");
b.Property<int>("InvalidLoginAttemptCount")
.HasColumnType("INTEGER");
b.Property<DateTime?>("LastActivityDate")
2020-05-15 14:24:01 -07:00
.HasColumnType("TEXT");
b.Property<DateTime?>("LastLoginDate")
2020-05-15 14:24:01 -07:00
.HasColumnType("TEXT");
2020-05-04 13:00:41 -07:00
b.Property<int?>("LoginAttemptsBeforeLockout")
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<int?>("MaxParentalAgeRating")
2020-05-04 13:00:41 -07:00
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<bool>("MustUpdatePassword")
.HasColumnType("INTEGER");
2020-05-04 13:00:41 -07:00
2020-05-15 14:24:01 -07:00
b.Property<string>("Password")
2020-05-04 13:00:41 -07:00
.HasColumnType("TEXT")
.HasMaxLength(65535);
2020-05-15 14:24:01 -07:00
b.Property<string>("PasswordResetProviderId")
.IsRequired()
2020-05-04 13:00:41 -07:00
.HasColumnType("TEXT")
2020-05-15 14:24:01 -07:00
.HasMaxLength(255);
2020-05-04 13:00:41 -07:00
b.Property<bool>("PlayDefaultAudioTrack")
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<bool>("RememberAudioSelections")
2020-05-04 13:00:41 -07:00
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<bool>("RememberSubtitleSelections")
.HasColumnType("INTEGER");
b.Property<int?>("RemoteClientBitrateLimit")
2020-05-04 13:00:41 -07:00
.HasColumnType("INTEGER");
b.Property<uint>("RowVersion")
.IsConcurrencyToken()
.HasColumnType("INTEGER");
2020-05-15 14:24:01 -07:00
b.Property<string>("SubtitleLanguagePreference")
2020-05-04 13:00:41 -07:00
.HasColumnType("TEXT")
.HasMaxLength(255);
2020-05-15 14:24:01 -07:00
b.Property<int>("SubtitleMode")
.HasColumnType("INTEGER");
2020-05-04 13:00:41 -07:00
2020-05-26 18:20:55 -07:00
b.Property<int>("SyncPlayAccess")
.HasColumnType("INTEGER");
2020-05-04 13:00:41 -07:00
b.Property<string>("Username")
.IsRequired()
.HasColumnType("TEXT")
.HasMaxLength(255);
b.HasKey("Id");
2020-05-15 14:24:01 -07:00
b.ToTable("Users");
});
modelBuilder.Entity("Jellyfin.Data.Entities.AccessSchedule", b =>
{
b.HasOne("Jellyfin.Data.Entities.User", null)
.WithMany("AccessSchedules")
.HasForeignKey("UserId")
.OnDelete(DeleteBehavior.Cascade)
2020-06-30 18:44:41 -07:00
.IsRequired();
});
modelBuilder.Entity("Jellyfin.Data.Entities.DisplayPreferences", b =>
{
b.HasOne("Jellyfin.Data.Entities.User", null)
.WithMany("DisplayPreferences")
.HasForeignKey("UserId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
});
modelBuilder.Entity("Jellyfin.Data.Entities.HomeSection", b =>
{
b.HasOne("Jellyfin.Data.Entities.DisplayPreferences", null)
.WithMany("HomeSections")
.HasForeignKey("DisplayPreferencesId")
.OnDelete(DeleteBehavior.Cascade)
2020-05-15 14:24:01 -07:00
.IsRequired();
2020-05-04 13:00:41 -07:00
});
2020-06-13 13:38:17 -07:00
modelBuilder.Entity("Jellyfin.Data.Entities.ImageInfo", b =>
{
b.HasOne("Jellyfin.Data.Entities.User", null)
.WithOne("ProfileImage")
.HasForeignKey("Jellyfin.Data.Entities.ImageInfo", "UserId");
});
2020-05-04 13:00:41 -07:00
modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>
{
b.HasOne("Jellyfin.Data.Entities.User", null)
.WithMany("Permissions")
2020-05-15 14:24:01 -07:00
.HasForeignKey("Permission_Permissions_Guid");
2020-05-04 13:00:41 -07:00
});
modelBuilder.Entity("Jellyfin.Data.Entities.Preference", b =>
{
2020-05-15 14:24:01 -07:00
b.HasOne("Jellyfin.Data.Entities.User", null)
2020-05-04 13:00:41 -07:00
.WithMany("Preferences")
2020-05-15 14:24:01 -07:00
.HasForeignKey("Preference_Preferences_Guid");
2020-05-04 13:00:41 -07:00
});
2020-05-02 15:32:22 -07:00
#pragma warning restore 612, 618
}
}
}