Regenerate migrations

This commit is contained in:
Patrick Barron 2020-06-13 11:56:18 -04:00
parent 103c9b7162
commit 84f0cf6cc6
3 changed files with 18 additions and 24 deletions

View File

@ -1,7 +1,4 @@
#pragma warning disable CS1591 // <auto-generated />
#pragma warning disable SA1601
// <auto-generated />
using System; using System;
using Jellyfin.Server.Implementations; using Jellyfin.Server.Implementations;
using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore;
@ -12,7 +9,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
namespace Jellyfin.Server.Implementations.Migrations namespace Jellyfin.Server.Implementations.Migrations
{ {
[DbContext(typeof(JellyfinDb))] [DbContext(typeof(JellyfinDb))]
[Migration("20200531020729_AddUsers")] [Migration("20200613155524_AddUsers")]
partial class AddUsers partial class AddUsers
{ {
protected override void BuildTargetModel(ModelBuilder modelBuilder) protected override void BuildTargetModel(ModelBuilder modelBuilder)
@ -44,7 +41,7 @@ namespace Jellyfin.Server.Implementations.Migrations
b.HasIndex("UserId"); b.HasIndex("UserId");
b.ToTable("AccessSchedule"); b.ToTable("AccessSchedules");
}); });
modelBuilder.Entity("Jellyfin.Data.Entities.ActivityLog", b => modelBuilder.Entity("Jellyfin.Data.Entities.ActivityLog", b =>
@ -109,7 +106,7 @@ namespace Jellyfin.Server.Implementations.Migrations
b.HasKey("Id"); b.HasKey("Id");
b.ToTable("ImageInfo"); b.ToTable("ImageInfos");
}); });
modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b => modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>

View File

@ -1,7 +1,4 @@
#pragma warning disable CS1591 using System;
#pragma warning disable SA1601
using System;
using Microsoft.EntityFrameworkCore.Migrations; using Microsoft.EntityFrameworkCore.Migrations;
namespace Jellyfin.Server.Implementations.Migrations namespace Jellyfin.Server.Implementations.Migrations
@ -11,7 +8,7 @@ namespace Jellyfin.Server.Implementations.Migrations
protected override void Up(MigrationBuilder migrationBuilder) protected override void Up(MigrationBuilder migrationBuilder)
{ {
migrationBuilder.CreateTable( migrationBuilder.CreateTable(
name: "ImageInfo", name: "ImageInfos",
schema: "jellyfin", schema: "jellyfin",
columns: table => new columns: table => new
{ {
@ -22,7 +19,7 @@ namespace Jellyfin.Server.Implementations.Migrations
}, },
constraints: table => constraints: table =>
{ {
table.PrimaryKey("PK_ImageInfo", x => x.Id); table.PrimaryKey("PK_ImageInfos", x => x.Id);
}); });
migrationBuilder.CreateTable( migrationBuilder.CreateTable(
@ -65,16 +62,16 @@ namespace Jellyfin.Server.Implementations.Migrations
{ {
table.PrimaryKey("PK_Users", x => x.Id); table.PrimaryKey("PK_Users", x => x.Id);
table.ForeignKey( table.ForeignKey(
name: "FK_Users_ImageInfo_ProfileImageId", name: "FK_Users_ImageInfos_ProfileImageId",
column: x => x.ProfileImageId, column: x => x.ProfileImageId,
principalSchema: "jellyfin", principalSchema: "jellyfin",
principalTable: "ImageInfo", principalTable: "ImageInfos",
principalColumn: "Id", principalColumn: "Id",
onDelete: ReferentialAction.Restrict); onDelete: ReferentialAction.Restrict);
}); });
migrationBuilder.CreateTable( migrationBuilder.CreateTable(
name: "AccessSchedule", name: "AccessSchedules",
schema: "jellyfin", schema: "jellyfin",
columns: table => new columns: table => new
{ {
@ -87,9 +84,9 @@ namespace Jellyfin.Server.Implementations.Migrations
}, },
constraints: table => constraints: table =>
{ {
table.PrimaryKey("PK_AccessSchedule", x => x.Id); table.PrimaryKey("PK_AccessSchedules", x => x.Id);
table.ForeignKey( table.ForeignKey(
name: "FK_AccessSchedule_Users_UserId", name: "FK_AccessSchedules_Users_UserId",
column: x => x.UserId, column: x => x.UserId,
principalSchema: "jellyfin", principalSchema: "jellyfin",
principalTable: "Users", principalTable: "Users",
@ -146,9 +143,9 @@ namespace Jellyfin.Server.Implementations.Migrations
}); });
migrationBuilder.CreateIndex( migrationBuilder.CreateIndex(
name: "IX_AccessSchedule_UserId", name: "IX_AccessSchedules_UserId",
schema: "jellyfin", schema: "jellyfin",
table: "AccessSchedule", table: "AccessSchedules",
column: "UserId"); column: "UserId");
migrationBuilder.CreateIndex( migrationBuilder.CreateIndex(
@ -173,7 +170,7 @@ namespace Jellyfin.Server.Implementations.Migrations
protected override void Down(MigrationBuilder migrationBuilder) protected override void Down(MigrationBuilder migrationBuilder)
{ {
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "AccessSchedule", name: "AccessSchedules",
schema: "jellyfin"); schema: "jellyfin");
migrationBuilder.DropTable( migrationBuilder.DropTable(
@ -189,7 +186,7 @@ namespace Jellyfin.Server.Implementations.Migrations
schema: "jellyfin"); schema: "jellyfin");
migrationBuilder.DropTable( migrationBuilder.DropTable(
name: "ImageInfo", name: "ImageInfos",
schema: "jellyfin"); schema: "jellyfin");
} }
} }

View File

@ -39,7 +39,7 @@ namespace Jellyfin.Server.Implementations.Migrations
b.HasIndex("UserId"); b.HasIndex("UserId");
b.ToTable("AccessSchedule"); b.ToTable("AccessSchedules");
}); });
modelBuilder.Entity("Jellyfin.Data.Entities.ActivityLog", b => modelBuilder.Entity("Jellyfin.Data.Entities.ActivityLog", b =>
@ -104,7 +104,7 @@ namespace Jellyfin.Server.Implementations.Migrations
b.HasKey("Id"); b.HasKey("Id");
b.ToTable("ImageInfo"); b.ToTable("ImageInfos");
}); });
modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b => modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>