Migration to modify required fields on games and dependent entities
This commit is contained in:
parent
3c62e795e5
commit
6156c87135
3 changed files with 1124 additions and 19 deletions
1021
LANCommander/Migrations/20230113234542_UpdateActionAndMultiplayerModelRequired.Designer.cs
generated
Normal file
1021
LANCommander/Migrations/20230113234542_UpdateActionAndMultiplayerModelRequired.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load diff
|
@ -0,0 +1,87 @@
|
|||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace LANCommander.Migrations
|
||||
{
|
||||
public partial class UpdateActionAndMultiplayerModelRequired : Migration
|
||||
{
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "Description",
|
||||
table: "MultiplayerModes",
|
||||
type: "TEXT",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "TEXT");
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "WorkingDirectory",
|
||||
table: "Actions",
|
||||
type: "TEXT",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "TEXT");
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "Path",
|
||||
table: "Actions",
|
||||
type: "TEXT",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "TEXT");
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "Arguments",
|
||||
table: "Actions",
|
||||
type: "TEXT",
|
||||
nullable: true,
|
||||
oldClrType: typeof(string),
|
||||
oldType: "TEXT");
|
||||
}
|
||||
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "Description",
|
||||
table: "MultiplayerModes",
|
||||
type: "TEXT",
|
||||
nullable: false,
|
||||
defaultValue: "",
|
||||
oldClrType: typeof(string),
|
||||
oldType: "TEXT",
|
||||
oldNullable: true);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "WorkingDirectory",
|
||||
table: "Actions",
|
||||
type: "TEXT",
|
||||
nullable: false,
|
||||
defaultValue: "",
|
||||
oldClrType: typeof(string),
|
||||
oldType: "TEXT",
|
||||
oldNullable: true);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "Path",
|
||||
table: "Actions",
|
||||
type: "TEXT",
|
||||
nullable: false,
|
||||
defaultValue: "",
|
||||
oldClrType: typeof(string),
|
||||
oldType: "TEXT",
|
||||
oldNullable: true);
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "Arguments",
|
||||
table: "Actions",
|
||||
type: "TEXT",
|
||||
nullable: false,
|
||||
defaultValue: "",
|
||||
oldClrType: typeof(string),
|
||||
oldType: "TEXT",
|
||||
oldNullable: true);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -29,7 +29,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("GamesId");
|
||||
|
||||
b.ToTable("CategoryGame", (string)null);
|
||||
b.ToTable("CategoryGame");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("GameDeveloper", b =>
|
||||
|
@ -44,7 +44,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("GameId");
|
||||
|
||||
b.ToTable("GameDeveloper", (string)null);
|
||||
b.ToTable("GameDeveloper");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("GameGenre", b =>
|
||||
|
@ -59,7 +59,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("GenresId");
|
||||
|
||||
b.ToTable("GameGenre", (string)null);
|
||||
b.ToTable("GameGenre");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("GamePublisher", b =>
|
||||
|
@ -74,7 +74,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("PublisherId");
|
||||
|
||||
b.ToTable("GamePublisher", (string)null);
|
||||
b.ToTable("GamePublisher");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("GameTag", b =>
|
||||
|
@ -89,7 +89,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("TagsId");
|
||||
|
||||
b.ToTable("GameTag", (string)null);
|
||||
b.ToTable("GameTag");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.Action", b =>
|
||||
|
@ -99,7 +99,6 @@ namespace LANCommander.Migrations
|
|||
.HasColumnType("TEXT");
|
||||
|
||||
b.Property<string>("Arguments")
|
||||
.IsRequired()
|
||||
.HasColumnType("TEXT");
|
||||
|
||||
b.Property<Guid?>("CreatedById")
|
||||
|
@ -116,7 +115,6 @@ namespace LANCommander.Migrations
|
|||
.HasColumnType("TEXT");
|
||||
|
||||
b.Property<string>("Path")
|
||||
.IsRequired()
|
||||
.HasColumnType("TEXT");
|
||||
|
||||
b.Property<bool>("PrimaryAction")
|
||||
|
@ -129,7 +127,6 @@ namespace LANCommander.Migrations
|
|||
.HasColumnType("TEXT");
|
||||
|
||||
b.Property<string>("WorkingDirectory")
|
||||
.IsRequired()
|
||||
.HasColumnType("TEXT");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
@ -140,7 +137,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("Actions", (string)null);
|
||||
b.ToTable("Actions");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.Archive", b =>
|
||||
|
@ -194,7 +191,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("Archive", (string)null);
|
||||
b.ToTable("Archive");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.Category", b =>
|
||||
|
@ -230,7 +227,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("Categories", (string)null);
|
||||
b.ToTable("Categories");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.Company", b =>
|
||||
|
@ -261,7 +258,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("Companies", (string)null);
|
||||
b.ToTable("Companies");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.Game", b =>
|
||||
|
@ -313,7 +310,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("Games", (string)null);
|
||||
b.ToTable("Games");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.Genre", b =>
|
||||
|
@ -344,7 +341,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("Genres", (string)null);
|
||||
b.ToTable("Genres");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.Key", b =>
|
||||
|
@ -404,7 +401,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("Keys", (string)null);
|
||||
b.ToTable("Keys");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.MultiplayerMode", b =>
|
||||
|
@ -420,10 +417,10 @@ namespace LANCommander.Migrations
|
|||
.HasColumnType("TEXT");
|
||||
|
||||
b.Property<string>("Description")
|
||||
.IsRequired()
|
||||
.HasColumnType("TEXT");
|
||||
|
||||
b.Property<Guid>("GameId")
|
||||
b.Property<Guid?>("GameId")
|
||||
.IsRequired()
|
||||
.HasColumnType("TEXT");
|
||||
|
||||
b.Property<int>("MaxPlayers")
|
||||
|
@ -455,7 +452,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("MultiplayerModes", (string)null);
|
||||
b.ToTable("MultiplayerModes");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.Role", b =>
|
||||
|
@ -513,7 +510,7 @@ namespace LANCommander.Migrations
|
|||
|
||||
b.HasIndex("UpdatedById");
|
||||
|
||||
b.ToTable("Tags", (string)null);
|
||||
b.ToTable("Tags");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("LANCommander.Data.Models.User", b =>
|
||||
|
|
Loading…
Add table
Reference in a new issue