|
|
@ -5,7 +5,7 @@
|
|
|
|
namespace EntityFrameworkLOL.Migrations
|
|
|
|
namespace EntityFrameworkLOL.Migrations
|
|
|
|
{
|
|
|
|
{
|
|
|
|
/// <inheritdoc />
|
|
|
|
/// <inheritdoc />
|
|
|
|
public partial class MigrationWallah4 : Migration
|
|
|
|
public partial class MigrationWallah5 : Migration
|
|
|
|
{
|
|
|
|
{
|
|
|
|
/// <inheritdoc />
|
|
|
|
/// <inheritdoc />
|
|
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
|
@ -73,11 +73,13 @@ namespace EntityFrameworkLOL.Migrations
|
|
|
|
name: "SkillType",
|
|
|
|
name: "SkillType",
|
|
|
|
columns: table => new
|
|
|
|
columns: table => new
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
Id = table.Column<int>(type: "INTEGER", nullable: false)
|
|
|
|
|
|
|
|
.Annotation("Sqlite:Autoincrement", true),
|
|
|
|
Type = table.Column<int>(type: "INTEGER", nullable: false)
|
|
|
|
Type = table.Column<int>(type: "INTEGER", nullable: false)
|
|
|
|
},
|
|
|
|
},
|
|
|
|
constraints: table =>
|
|
|
|
constraints: table =>
|
|
|
|
{
|
|
|
|
{
|
|
|
|
table.PrimaryKey("PK_SkillType", x => x.Type);
|
|
|
|
table.PrimaryKey("PK_SkillType", x => x.Id);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
@ -132,6 +134,25 @@ namespace EntityFrameworkLOL.Migrations
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
|
|
|
|
name: "Skill",
|
|
|
|
|
|
|
|
columns: table => new
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
Name = table.Column<string>(type: "TEXT", nullable: false),
|
|
|
|
|
|
|
|
Description = table.Column<string>(type: "TEXT", nullable: false),
|
|
|
|
|
|
|
|
TypeId = table.Column<int>(type: "INTEGER", nullable: false)
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
constraints: table =>
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
table.PrimaryKey("PK_Skill", x => x.Name);
|
|
|
|
|
|
|
|
table.ForeignKey(
|
|
|
|
|
|
|
|
name: "FK_Skill_SkillType_TypeId",
|
|
|
|
|
|
|
|
column: x => x.TypeId,
|
|
|
|
|
|
|
|
principalTable: "SkillType",
|
|
|
|
|
|
|
|
principalColumn: "Id",
|
|
|
|
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
name: "Skin",
|
|
|
|
name: "Skin",
|
|
|
|
columns: table => new
|
|
|
|
columns: table => new
|
|
|
@ -158,6 +179,30 @@ namespace EntityFrameworkLOL.Migrations
|
|
|
|
principalColumn: "Base64");
|
|
|
|
principalColumn: "Base64");
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateTable(
|
|
|
|
|
|
|
|
name: "ChampionEntitySkillEntity",
|
|
|
|
|
|
|
|
columns: table => new
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
ChampionsName = table.Column<string>(type: "TEXT", nullable: false),
|
|
|
|
|
|
|
|
SkillsName = table.Column<string>(type: "TEXT", nullable: false)
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
constraints: table =>
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
table.PrimaryKey("PK_ChampionEntitySkillEntity", x => new { x.ChampionsName, x.SkillsName });
|
|
|
|
|
|
|
|
table.ForeignKey(
|
|
|
|
|
|
|
|
name: "FK_ChampionEntitySkillEntity_Champion_ChampionsName",
|
|
|
|
|
|
|
|
column: x => x.ChampionsName,
|
|
|
|
|
|
|
|
principalTable: "Champion",
|
|
|
|
|
|
|
|
principalColumn: "Name",
|
|
|
|
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
|
|
|
|
table.ForeignKey(
|
|
|
|
|
|
|
|
name: "FK_ChampionEntitySkillEntity_Skill_SkillsName",
|
|
|
|
|
|
|
|
column: x => x.SkillsName,
|
|
|
|
|
|
|
|
principalTable: "Skill",
|
|
|
|
|
|
|
|
principalColumn: "Name",
|
|
|
|
|
|
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
name: "IX_Champion_ClassId",
|
|
|
|
name: "IX_Champion_ClassId",
|
|
|
|
table: "Champion",
|
|
|
|
table: "Champion",
|
|
|
@ -168,6 +213,11 @@ namespace EntityFrameworkLOL.Migrations
|
|
|
|
table: "Champion",
|
|
|
|
table: "Champion",
|
|
|
|
column: "ImageBase64");
|
|
|
|
column: "ImageBase64");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
|
|
|
|
name: "IX_ChampionEntitySkillEntity_SkillsName",
|
|
|
|
|
|
|
|
table: "ChampionEntitySkillEntity",
|
|
|
|
|
|
|
|
column: "SkillsName");
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
name: "IX_Rune_FamilyId",
|
|
|
|
name: "IX_Rune_FamilyId",
|
|
|
|
table: "Rune",
|
|
|
|
table: "Rune",
|
|
|
@ -178,6 +228,11 @@ namespace EntityFrameworkLOL.Migrations
|
|
|
|
table: "Rune",
|
|
|
|
table: "Rune",
|
|
|
|
column: "ImageBase64");
|
|
|
|
column: "ImageBase64");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
|
|
|
|
name: "IX_Skill_TypeId",
|
|
|
|
|
|
|
|
table: "Skill",
|
|
|
|
|
|
|
|
column: "TypeId");
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
migrationBuilder.CreateIndex(
|
|
|
|
name: "IX_Skin_ChampionSkinName",
|
|
|
|
name: "IX_Skin_ChampionSkinName",
|
|
|
|
table: "Skin",
|
|
|
|
table: "Skin",
|
|
|
@ -195,6 +250,9 @@ namespace EntityFrameworkLOL.Migrations
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
name: "Category");
|
|
|
|
name: "Category");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
|
|
|
|
name: "ChampionEntitySkillEntity");
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
name: "Rune");
|
|
|
|
name: "Rune");
|
|
|
|
|
|
|
|
|
|
|
@ -202,10 +260,10 @@ namespace EntityFrameworkLOL.Migrations
|
|
|
|
name: "RunePage");
|
|
|
|
name: "RunePage");
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
name: "SkillType");
|
|
|
|
name: "Skin");
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
name: "Skin");
|
|
|
|
name: "Skill");
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
name: "RuneFamily");
|
|
|
|
name: "RuneFamily");
|
|
|
@ -213,6 +271,9 @@ namespace EntityFrameworkLOL.Migrations
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
name: "Champion");
|
|
|
|
name: "Champion");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
|
|
|
|
name: "SkillType");
|
|
|
|
|
|
|
|
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
migrationBuilder.DropTable(
|
|
|
|
name: "ChampionClass");
|
|
|
|
name: "ChampionClass");
|
|
|
|
|
|
|
|
|