diff --git a/.azuredevops/pipelines/publish-job.yml b/.azuredevops/pipelines/publish-job.yml
index 23449f30c..bcf07a168 100644
--- a/.azuredevops/pipelines/publish-job.yml
+++ b/.azuredevops/pipelines/publish-job.yml
@@ -1,6 +1,7 @@
variables:
- template: templates/variables.yml
+ - isMain: $[eq(variables['Build.SourceBranch'], 'refs/heads/feature/v4')]
stages:
- stage: build
@@ -90,4 +91,4 @@ stages:
isPreRelease: true
changeLogCompareToRelease: 'lastNonDraftRelease'
changeLogType: 'commitBased'
- condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/feature/v4'))
+ condition: and(succeeded(), eq(variables.isMain, true))
diff --git a/src/Ombi.Store/Migrations/OmbiMySql/20200829205234_Charset.Designer.cs b/src/Ombi.Store/Migrations/OmbiMySql/20200829205234_Charset.Designer.cs
new file mode 100644
index 000000000..c6251941f
--- /dev/null
+++ b/src/Ombi.Store/Migrations/OmbiMySql/20200829205234_Charset.Designer.cs
@@ -0,0 +1,1152 @@
+//
+using System;
+using Microsoft.EntityFrameworkCore;
+using Microsoft.EntityFrameworkCore.Infrastructure;
+using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
+using Ombi.Store.Context.MySql;
+
+namespace Ombi.Store.Migrations.OmbiMySql
+{
+ [DbContext(typeof(OmbiMySqlContext))]
+ [Migration("20200829205234_Charset")]
+ partial class Charset
+ {
+ protected override void BuildTargetModel(ModelBuilder modelBuilder)
+ {
+#pragma warning disable 612, 618
+ modelBuilder
+ .HasAnnotation("ProductVersion", "3.1.1")
+ .HasAnnotation("Relational:MaxIdentifierLength", 64);
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRole", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("varchar(255)");
+
+ b.Property("ConcurrencyStamp")
+ .IsConcurrencyToken()
+ .HasColumnType("longtext");
+
+ b.Property("Name")
+ .HasColumnType("varchar(256)")
+ .HasMaxLength(256);
+
+ b.Property("NormalizedName")
+ .HasColumnType("varchar(256)")
+ .HasMaxLength(256);
+
+ b.HasKey("Id");
+
+ b.HasIndex("NormalizedName")
+ .IsUnique()
+ .HasName("RoleNameIndex");
+
+ b.ToTable("AspNetRoles");
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("ClaimType")
+ .HasColumnType("longtext");
+
+ b.Property("ClaimValue")
+ .HasColumnType("longtext");
+
+ b.Property("RoleId")
+ .IsRequired()
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("RoleId");
+
+ b.ToTable("AspNetRoleClaims");
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("ClaimType")
+ .HasColumnType("longtext");
+
+ b.Property("ClaimValue")
+ .HasColumnType("longtext");
+
+ b.Property("UserId")
+ .IsRequired()
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("AspNetUserClaims");
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin", b =>
+ {
+ b.Property("LoginProvider")
+ .HasColumnType("varchar(255)");
+
+ b.Property("ProviderKey")
+ .HasColumnType("varchar(255)");
+
+ b.Property("ProviderDisplayName")
+ .HasColumnType("longtext");
+
+ b.Property("UserId")
+ .IsRequired()
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("LoginProvider", "ProviderKey");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("AspNetUserLogins");
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole", b =>
+ {
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.Property("RoleId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("UserId", "RoleId");
+
+ b.HasIndex("RoleId");
+
+ b.ToTable("AspNetUserRoles");
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken", b =>
+ {
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.Property("LoginProvider")
+ .HasColumnType("varchar(255)");
+
+ b.Property("Name")
+ .HasColumnType("varchar(255)");
+
+ b.Property("Value")
+ .HasColumnType("longtext");
+
+ b.HasKey("UserId", "LoginProvider", "Name");
+
+ b.ToTable("AspNetUserTokens");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Audit", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("AuditArea")
+ .HasColumnType("int");
+
+ b.Property("AuditType")
+ .HasColumnType("int");
+
+ b.Property("DateTime")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Description")
+ .HasColumnType("longtext");
+
+ b.Property("User")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.ToTable("Audit");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.MobileDevices", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("AddedAt")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Token")
+ .HasColumnType("longtext");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("MobileDevices");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.NotificationTemplates", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Agent")
+ .HasColumnType("int");
+
+ b.Property("Enabled")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Message")
+ .HasColumnType("longtext");
+
+ b.Property("NotificationType")
+ .HasColumnType("int");
+
+ b.Property("Subject")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.ToTable("NotificationTemplates");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.NotificationUserId", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("AddedAt")
+ .HasColumnType("datetime(6)");
+
+ b.Property("PlayerId")
+ .HasColumnType("longtext");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("NotificationUserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.OmbiUser", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("varchar(255)");
+
+ b.Property("AccessFailedCount")
+ .HasColumnType("int");
+
+ b.Property("Alias")
+ .HasColumnType("longtext");
+
+ b.Property("ConcurrencyStamp")
+ .IsConcurrencyToken()
+ .HasColumnType("longtext");
+
+ b.Property("Email")
+ .HasColumnType("varchar(256)")
+ .HasMaxLength(256);
+
+ b.Property("EmailConfirmed")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("EpisodeRequestLimit")
+ .HasColumnType("int");
+
+ b.Property("Language")
+ .HasColumnType("longtext");
+
+ b.Property("LastLoggedIn")
+ .HasColumnType("datetime(6)");
+
+ b.Property("LockoutEnabled")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("LockoutEnd")
+ .HasColumnType("datetime(6)");
+
+ b.Property("MovieRequestLimit")
+ .HasColumnType("int");
+
+ b.Property("MusicRequestLimit")
+ .HasColumnType("int");
+
+ b.Property("NormalizedEmail")
+ .HasColumnType("varchar(256)")
+ .HasMaxLength(256);
+
+ b.Property("NormalizedUserName")
+ .HasColumnType("varchar(256)")
+ .HasMaxLength(256);
+
+ b.Property("PasswordHash")
+ .HasColumnType("longtext");
+
+ b.Property("PhoneNumber")
+ .HasColumnType("longtext");
+
+ b.Property("PhoneNumberConfirmed")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("ProviderUserId")
+ .HasColumnType("longtext");
+
+ b.Property("SecurityStamp")
+ .HasColumnType("longtext");
+
+ b.Property("TwoFactorEnabled")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("UserAccessToken")
+ .HasColumnType("longtext");
+
+ b.Property("UserName")
+ .HasColumnType("varchar(256)")
+ .HasMaxLength(256);
+
+ b.Property("UserType")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("NormalizedEmail")
+ .HasName("EmailIndex");
+
+ b.HasIndex("NormalizedUserName")
+ .IsUnique()
+ .HasName("UserNameIndex");
+
+ b.ToTable("AspNetUsers");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.RecentlyAddedLog", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("AddedAt")
+ .HasColumnType("datetime(6)");
+
+ b.Property("AlbumId")
+ .HasColumnType("longtext");
+
+ b.Property("ContentId")
+ .HasColumnType("int");
+
+ b.Property("ContentType")
+ .HasColumnType("int");
+
+ b.Property("EpisodeNumber")
+ .HasColumnType("int");
+
+ b.Property("SeasonNumber")
+ .HasColumnType("int");
+
+ b.Property("Type")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.ToTable("RecentlyAddedLog");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.RequestQueue", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Completed")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Dts")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Error")
+ .HasColumnType("longtext");
+
+ b.Property("RequestId")
+ .HasColumnType("int");
+
+ b.Property("RetryCount")
+ .HasColumnType("int");
+
+ b.Property("Type")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.ToTable("RequestQueue");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.RequestSubscription", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("RequestId")
+ .HasColumnType("int");
+
+ b.Property("RequestType")
+ .HasColumnType("int");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("RequestSubscription");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.AlbumRequest", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Approved")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("ArtistName")
+ .HasColumnType("longtext");
+
+ b.Property("Available")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Cover")
+ .HasColumnType("longtext");
+
+ b.Property("Denied")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("DeniedReason")
+ .HasColumnType("longtext");
+
+ b.Property("Disk")
+ .HasColumnType("longtext");
+
+ b.Property("ForeignAlbumId")
+ .HasColumnType("longtext");
+
+ b.Property("ForeignArtistId")
+ .HasColumnType("longtext");
+
+ b.Property("MarkedAsApproved")
+ .HasColumnType("datetime(6)");
+
+ b.Property("MarkedAsAvailable")
+ .HasColumnType("datetime(6)");
+
+ b.Property("MarkedAsDenied")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Rating")
+ .HasColumnType("decimal(65,30)");
+
+ b.Property("ReleaseDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("RequestType")
+ .HasColumnType("int");
+
+ b.Property("RequestedByAlias")
+ .HasColumnType("longtext");
+
+ b.Property("RequestedDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("RequestedUserId")
+ .HasColumnType("varchar(255)");
+
+ b.Property("Title")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.HasIndex("RequestedUserId");
+
+ b.ToTable("AlbumRequests");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.ChildRequests", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Approved")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Available")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Denied")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("DeniedReason")
+ .HasColumnType("longtext");
+
+ b.Property("IssueId")
+ .HasColumnType("int");
+
+ b.Property("MarkedAsApproved")
+ .HasColumnType("datetime(6)");
+
+ b.Property("MarkedAsAvailable")
+ .HasColumnType("datetime(6)");
+
+ b.Property("MarkedAsDenied")
+ .HasColumnType("datetime(6)");
+
+ b.Property("ParentRequestId")
+ .HasColumnType("int");
+
+ b.Property("RequestType")
+ .HasColumnType("int");
+
+ b.Property("RequestedByAlias")
+ .HasColumnType("longtext");
+
+ b.Property("RequestedDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("RequestedUserId")
+ .HasColumnType("varchar(255)");
+
+ b.Property("SeriesType")
+ .HasColumnType("int");
+
+ b.Property("Title")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.HasIndex("ParentRequestId");
+
+ b.HasIndex("RequestedUserId");
+
+ b.ToTable("ChildRequests");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.IssueCategory", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Value")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.ToTable("IssueCategory");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.IssueComments", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Comment")
+ .HasColumnType("longtext");
+
+ b.Property("Date")
+ .HasColumnType("datetime(6)");
+
+ b.Property("IssuesId")
+ .HasColumnType("int");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("IssuesId");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("IssueComments");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.Issues", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("CreatedDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Description")
+ .HasColumnType("longtext");
+
+ b.Property("IssueCategoryId")
+ .HasColumnType("int");
+
+ b.Property("IssueId")
+ .HasColumnType("int");
+
+ b.Property("ProviderId")
+ .HasColumnType("longtext");
+
+ b.Property("RequestId")
+ .HasColumnType("int");
+
+ b.Property("RequestType")
+ .HasColumnType("int");
+
+ b.Property("ResovledDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Status")
+ .HasColumnType("int");
+
+ b.Property("Subject")
+ .HasColumnType("longtext");
+
+ b.Property("Title")
+ .HasColumnType("longtext");
+
+ b.Property("UserReportedId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("IssueCategoryId");
+
+ b.HasIndex("IssueId");
+
+ b.HasIndex("UserReportedId");
+
+ b.ToTable("Issues");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.MovieRequests", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Approved")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Available")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Background")
+ .HasColumnType("longtext");
+
+ b.Property("Denied")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("DeniedReason")
+ .HasColumnType("longtext");
+
+ b.Property("DigitalReleaseDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("ImdbId")
+ .HasColumnType("longtext");
+
+ b.Property("IssueId")
+ .HasColumnType("int");
+
+ b.Property("LangCode")
+ .HasColumnType("longtext");
+
+ b.Property("MarkedAsApproved")
+ .HasColumnType("datetime(6)");
+
+ b.Property("MarkedAsAvailable")
+ .HasColumnType("datetime(6)");
+
+ b.Property("MarkedAsDenied")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Overview")
+ .HasColumnType("longtext");
+
+ b.Property("PosterPath")
+ .HasColumnType("longtext");
+
+ b.Property("QualityOverride")
+ .HasColumnType("int");
+
+ b.Property("ReleaseDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("RequestType")
+ .HasColumnType("int");
+
+ b.Property("RequestedByAlias")
+ .HasColumnType("longtext");
+
+ b.Property("RequestedDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("RequestedUserId")
+ .HasColumnType("varchar(255)");
+
+ b.Property("RootPathOverride")
+ .HasColumnType("int");
+
+ b.Property("Status")
+ .HasColumnType("longtext");
+
+ b.Property("TheMovieDbId")
+ .HasColumnType("int");
+
+ b.Property("Title")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.HasIndex("RequestedUserId");
+
+ b.ToTable("MovieRequests");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.RequestLog", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("EpisodeCount")
+ .HasColumnType("int");
+
+ b.Property("RequestDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("RequestId")
+ .HasColumnType("int");
+
+ b.Property("RequestType")
+ .HasColumnType("int");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("RequestLog");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.TvRequests", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Background")
+ .HasColumnType("longtext");
+
+ b.Property("ImdbId")
+ .HasColumnType("longtext");
+
+ b.Property("Overview")
+ .HasColumnType("longtext");
+
+ b.Property("PosterPath")
+ .HasColumnType("longtext");
+
+ b.Property("QualityOverride")
+ .HasColumnType("int");
+
+ b.Property("ReleaseDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("RootFolder")
+ .HasColumnType("int");
+
+ b.Property("Status")
+ .HasColumnType("longtext");
+
+ b.Property("Title")
+ .HasColumnType("longtext");
+
+ b.Property("TotalSeasons")
+ .HasColumnType("int");
+
+ b.Property("TvDbId")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.ToTable("TvRequests");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Tokens", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Token")
+ .HasColumnType("longtext");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("Tokens");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.UserNotificationPreferences", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Agent")
+ .HasColumnType("int");
+
+ b.Property("Enabled")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.Property("Value")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("UserNotificationPreferences");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.UserQualityProfiles", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("RadarrQualityProfile")
+ .HasColumnType("int");
+
+ b.Property("RadarrRootPath")
+ .HasColumnType("int");
+
+ b.Property("SonarrQualityProfile")
+ .HasColumnType("int");
+
+ b.Property("SonarrQualityProfileAnime")
+ .HasColumnType("int");
+
+ b.Property("SonarrRootPath")
+ .HasColumnType("int");
+
+ b.Property("SonarrRootPathAnime")
+ .HasColumnType("int");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("UserQualityProfiles");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Votes", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("Date")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Deleted")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("RequestId")
+ .HasColumnType("int");
+
+ b.Property("RequestType")
+ .HasColumnType("int");
+
+ b.Property("UserId")
+ .HasColumnType("varchar(255)");
+
+ b.Property("VoteType")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("UserId");
+
+ b.ToTable("Votes");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Repository.Requests.EpisodeRequests", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("AirDate")
+ .HasColumnType("datetime(6)");
+
+ b.Property("Approved")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("Available")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("EpisodeNumber")
+ .HasColumnType("int");
+
+ b.Property("Requested")
+ .HasColumnType("tinyint(1)");
+
+ b.Property("SeasonId")
+ .HasColumnType("int");
+
+ b.Property("Title")
+ .HasColumnType("longtext");
+
+ b.Property("Url")
+ .HasColumnType("longtext");
+
+ b.HasKey("Id");
+
+ b.HasIndex("SeasonId");
+
+ b.ToTable("EpisodeRequests");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Repository.Requests.SeasonRequests", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ b.Property("ChildRequestId")
+ .HasColumnType("int");
+
+ b.Property("SeasonNumber")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("ChildRequestId");
+
+ b.ToTable("SeasonRequests");
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim", b =>
+ {
+ b.HasOne("Microsoft.AspNetCore.Identity.IdentityRole", null)
+ .WithMany()
+ .HasForeignKey("RoleId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", null)
+ .WithMany()
+ .HasForeignKey("UserId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", null)
+ .WithMany()
+ .HasForeignKey("UserId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole", b =>
+ {
+ b.HasOne("Microsoft.AspNetCore.Identity.IdentityRole", null)
+ .WithMany()
+ .HasForeignKey("RoleId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("Ombi.Store.Entities.OmbiUser", null)
+ .WithMany()
+ .HasForeignKey("UserId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+ });
+
+ modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", null)
+ .WithMany()
+ .HasForeignKey("UserId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.MobileDevices", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany()
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.NotificationUserId", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany("NotificationUserIds")
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.RequestSubscription", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany()
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.AlbumRequest", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "RequestedUser")
+ .WithMany()
+ .HasForeignKey("RequestedUserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.ChildRequests", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.Requests.TvRequests", "ParentRequest")
+ .WithMany("ChildRequests")
+ .HasForeignKey("ParentRequestId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "RequestedUser")
+ .WithMany()
+ .HasForeignKey("RequestedUserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.IssueComments", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.Requests.Issues", "Issues")
+ .WithMany("Comments")
+ .HasForeignKey("IssuesId");
+
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany()
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.Issues", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.Requests.IssueCategory", "IssueCategory")
+ .WithMany()
+ .HasForeignKey("IssueCategoryId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("Ombi.Store.Entities.Requests.ChildRequests", null)
+ .WithMany("Issues")
+ .HasForeignKey("IssueId");
+
+ b.HasOne("Ombi.Store.Entities.Requests.MovieRequests", null)
+ .WithMany("Issues")
+ .HasForeignKey("IssueId");
+
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "UserReported")
+ .WithMany()
+ .HasForeignKey("UserReportedId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.MovieRequests", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "RequestedUser")
+ .WithMany()
+ .HasForeignKey("RequestedUserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Requests.RequestLog", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany()
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Tokens", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany()
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.UserNotificationPreferences", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany("UserNotificationPreferences")
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.UserQualityProfiles", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany()
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Entities.Votes", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.OmbiUser", "User")
+ .WithMany()
+ .HasForeignKey("UserId");
+ });
+
+ modelBuilder.Entity("Ombi.Store.Repository.Requests.EpisodeRequests", b =>
+ {
+ b.HasOne("Ombi.Store.Repository.Requests.SeasonRequests", "Season")
+ .WithMany("Episodes")
+ .HasForeignKey("SeasonId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+ });
+
+ modelBuilder.Entity("Ombi.Store.Repository.Requests.SeasonRequests", b =>
+ {
+ b.HasOne("Ombi.Store.Entities.Requests.ChildRequests", "ChildRequest")
+ .WithMany("SeasonRequests")
+ .HasForeignKey("ChildRequestId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+ });
+#pragma warning restore 612, 618
+ }
+ }
+}
diff --git a/src/Ombi.Store/Migrations/OmbiMySql/20200829205234_Charset.cs b/src/Ombi.Store/Migrations/OmbiMySql/20200829205234_Charset.cs
new file mode 100644
index 000000000..e782dbddc
--- /dev/null
+++ b/src/Ombi.Store/Migrations/OmbiMySql/20200829205234_Charset.cs
@@ -0,0 +1,1453 @@
+using Microsoft.EntityFrameworkCore.Migrations;
+
+namespace Ombi.Store.Migrations.OmbiMySql
+{
+ public partial class Charset : Migration
+ {
+ protected override void Up(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.AlterColumn(
+ name: "UserId",
+ table: "Votes",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "varchar(255) CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "UserId",
+ table: "UserQualityProfiles",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "varchar(255) CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Value",
+ table: "UserNotificationPreferences",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "UserId",
+ table: "UserNotificationPreferences",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "varchar(255) CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Title",
+ table: "TvRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Status",
+ table: "TvRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "PosterPath",
+ table: "TvRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Overview",
+ table: "TvRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "ImdbId",
+ table: "TvRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Background",
+ table: "TvRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "UserId",
+ table: "Tokens",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "varchar(255) CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Token",
+ table: "Tokens",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "UserId",
+ table: "RequestSubscription",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "varchar(255) CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Error",
+ table: "RequestQueue",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "UserId",
+ table: "RequestLog",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "varchar(255) CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "AlbumId",
+ table: "RecentlyAddedLog",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "UserId",
+ table: "NotificationUserId",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "varchar(255) CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "PlayerId",
+ table: "NotificationUserId",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Subject",
+ table: "NotificationTemplates",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Message",
+ table: "NotificationTemplates",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Title",
+ table: "MovieRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "Status",
+ table: "MovieRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "RequestedUserId",
+ table: "MovieRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "varchar(255) CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "RequestedByAlias",
+ table: "MovieRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn(
+ name: "PosterPath",
+ table: "MovieRequests",
+ nullable: true,
+ oldClrType: typeof(string),
+ oldType: "longtext CHARACTER SET utf8mb4",
+ oldNullable: true);
+
+ migrationBuilder.AlterColumn