exciting-aftermath/Portfolio.Infrastructure/Migrations/20250217210310_Initial.cs

78 lines
3.2 KiB
C#

using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Portfolio.Infrastructure.Migrations
{
/// <inheritdoc />
public partial class Initial : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "PokemonNatures",
columns: table => new
{
Id = table.Column<int>(type: "int", nullable: false)
.Annotation("SqlServer:Identity", "1, 1"),
Nature = table.Column<string>(type: "nvarchar(max)", nullable: false),
BerryRating = table.Column<int>(type: "int", nullable: false),
IngredientRating = table.Column<int>(type: "int", nullable: false),
SkillRating = table.Column<int>(type: "int", nullable: false)
},
constraints: table =>
{
table.PrimaryKey("PK_PokemonNatures", x => x.Id);
});
migrationBuilder.CreateTable(
name: "Pokemons",
columns: table => new
{
Id = table.Column<int>(type: "int", nullable: false)
.Annotation("SqlServer:Identity", "1, 1"),
PokemonId = table.Column<int>(type: "int", nullable: false),
PokemonName = table.Column<string>(type: "nvarchar(max)", nullable: false),
IsVariation = table.Column<bool>(type: "bit", nullable: false),
VariationName = table.Column<string>(type: "nvarchar(max)", nullable: false),
SleepType = table.Column<string>(type: "nvarchar(max)", nullable: false),
Speciality = table.Column<string>(type: "nvarchar(max)", nullable: false)
},
constraints: table =>
{
table.PrimaryKey("PK_Pokemons", x => x.Id);
});
migrationBuilder.CreateTable(
name: "PokemonSubskills",
columns: table => new
{
Id = table.Column<int>(type: "int", nullable: false)
.Annotation("SqlServer:Identity", "1, 1"),
SubSkill = table.Column<string>(type: "nvarchar(max)", nullable: false),
BerryRank = table.Column<int>(type: "int", nullable: false),
IngredientRank = table.Column<int>(type: "int", nullable: false),
SkillRank = table.Column<int>(type: "int", nullable: false)
},
constraints: table =>
{
table.PrimaryKey("PK_PokemonSubskills", x => x.Id);
});
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "PokemonNatures");
migrationBuilder.DropTable(
name: "Pokemons");
migrationBuilder.DropTable(
name: "PokemonSubskills");
}
}
}