|
|
|
@ -89,6 +89,30 @@ namespace Entities.Migrations
|
|
|
|
|
principalColumn: "Id");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
|
name: "ChampionEntityRunePageEntity",
|
|
|
|
|
columns: table => new
|
|
|
|
|
{
|
|
|
|
|
championsName = table.Column<string>(type: "TEXT", nullable: false),
|
|
|
|
|
runepagesId = table.Column<Guid>(type: "TEXT", nullable: false)
|
|
|
|
|
},
|
|
|
|
|
constraints: table =>
|
|
|
|
|
{
|
|
|
|
|
table.PrimaryKey("PK_ChampionEntityRunePageEntity", x => new { x.championsName, x.runepagesId });
|
|
|
|
|
table.ForeignKey(
|
|
|
|
|
name: "FK_ChampionEntityRunePageEntity_champions_championsName",
|
|
|
|
|
column: x => x.championsName,
|
|
|
|
|
principalTable: "champions",
|
|
|
|
|
principalColumn: "Name",
|
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
|
table.ForeignKey(
|
|
|
|
|
name: "FK_ChampionEntityRunePageEntity_runepages_runepagesId",
|
|
|
|
|
column: x => x.runepagesId,
|
|
|
|
|
principalTable: "runepages",
|
|
|
|
|
principalColumn: "Id",
|
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
|
name: "ChampionEntitySkillEntity",
|
|
|
|
|
columns: table => new
|
|
|
|
@ -113,6 +137,25 @@ namespace Entities.Migrations
|
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
|
name: "characteristics",
|
|
|
|
|
columns: table => new
|
|
|
|
|
{
|
|
|
|
|
Name = table.Column<string>(type: "TEXT", maxLength: 256, nullable: false),
|
|
|
|
|
ChampionForeignKey = table.Column<string>(type: "TEXT", nullable: false),
|
|
|
|
|
Value = table.Column<int>(type: "INTEGER", nullable: false)
|
|
|
|
|
},
|
|
|
|
|
constraints: table =>
|
|
|
|
|
{
|
|
|
|
|
table.PrimaryKey("PK_characteristics", x => new { x.Name, x.ChampionForeignKey });
|
|
|
|
|
table.ForeignKey(
|
|
|
|
|
name: "FK_characteristics_champions_ChampionForeignKey",
|
|
|
|
|
column: x => x.ChampionForeignKey,
|
|
|
|
|
principalTable: "champions",
|
|
|
|
|
principalColumn: "Name",
|
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
|
name: "skins",
|
|
|
|
|
columns: table => new
|
|
|
|
@ -177,12 +220,12 @@ namespace Entities.Migrations
|
|
|
|
|
migrationBuilder.InsertData(
|
|
|
|
|
table: "largeimages",
|
|
|
|
|
columns: new[] { "Id", "Base64" },
|
|
|
|
|
values: new object[] { new Guid("70d7aace-13a9-40e1-bd94-99790805f6d0"), "aaa" });
|
|
|
|
|
values: new object[] { new Guid("d3a490c6-fb49-475a-9134-47c2de9888d2"), "aaa" });
|
|
|
|
|
|
|
|
|
|
migrationBuilder.InsertData(
|
|
|
|
|
table: "runepages",
|
|
|
|
|
columns: new[] { "Id", "Name" },
|
|
|
|
|
values: new object[] { new Guid("a5a4f69b-5cbb-48c1-beb4-896bc9171714"), "Runepage_1" });
|
|
|
|
|
values: new object[] { new Guid("4ea04d4f-0a64-4d28-8d74-4499dbc541f2"), "Runepage_1" });
|
|
|
|
|
|
|
|
|
|
migrationBuilder.InsertData(
|
|
|
|
|
table: "runes",
|
|
|
|
@ -202,6 +245,15 @@ namespace Entities.Migrations
|
|
|
|
|
{ "White Star", "Random damage", 3 }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
migrationBuilder.InsertData(
|
|
|
|
|
table: "characteristics",
|
|
|
|
|
columns: new[] { "ChampionForeignKey", "Name", "Value" },
|
|
|
|
|
values: new object[,]
|
|
|
|
|
{
|
|
|
|
|
{ "Armure", "Défense", 75 },
|
|
|
|
|
{ "Dave", "Force", 50 }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
migrationBuilder.InsertData(
|
|
|
|
|
table: "skins",
|
|
|
|
|
columns: new[] { "Name", "ChampionForeignKey", "Description", "Icon", "ImageId", "Price" },
|
|
|
|
@ -211,6 +263,11 @@ namespace Entities.Migrations
|
|
|
|
|
{ "Dave de glace", "Dave", "Enneigé", "aaa", null, 7.99f }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
|
name: "IX_ChampionEntityRunePageEntity_runepagesId",
|
|
|
|
|
table: "ChampionEntityRunePageEntity",
|
|
|
|
|
column: "runepagesId");
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
|
name: "IX_ChampionEntitySkillEntity_SkillsName",
|
|
|
|
|
table: "ChampionEntitySkillEntity",
|
|
|
|
@ -221,6 +278,11 @@ namespace Entities.Migrations
|
|
|
|
|
table: "champions",
|
|
|
|
|
column: "ImageId");
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
|
name: "IX_characteristics_ChampionForeignKey",
|
|
|
|
|
table: "characteristics",
|
|
|
|
|
column: "ChampionForeignKey");
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
|
name: "IX_RunePageRuneEntity_runesName",
|
|
|
|
|
table: "RunePageRuneEntity",
|
|
|
|
@ -245,9 +307,15 @@ namespace Entities.Migrations
|
|
|
|
|
/// <inheritdoc />
|
|
|
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
|
|
|
{
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
|
name: "ChampionEntityRunePageEntity");
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
|
name: "ChampionEntitySkillEntity");
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
|
name: "characteristics");
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
|
name: "RunePageRuneEntity");
|
|
|
|
|
|