using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace DamageAssesment.Api.Locations.Migrations
{
    /// 
    public partial class InitialLocation : Migration
    {
        /// 
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.CreateTable(
                name: "Locations",
                columns: table => new
                {
                    Id = table.Column(type: "nvarchar(4)", maxLength: 4, nullable: false),
                    Name = table.Column(type: "nvarchar(50)", maxLength: 50, nullable: false),
                    MaintenanceCenter = table.Column(type: "nvarchar(1)", maxLength: 1, nullable: false),
                    SchoolType = table.Column(type: "nvarchar(2)", maxLength: 2, nullable: false),
                    RegionId = table.Column(type: "nvarchar(max)", nullable: false)
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_Locations", x => x.Id);
                });
            migrationBuilder.CreateTable(
                name: "Regions",
                columns: table => new
                {
                    Id = table.Column(type: "nvarchar(2)", maxLength: 2, nullable: false),
                    Name = table.Column(type: "nvarchar(50)", maxLength: 50, nullable: false),
                    Abbreviation = table.Column(type: "nvarchar(5)", maxLength: 5, nullable: false)
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_Regions", x => x.Id);
                });
        }
        /// 
        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropTable(
                name: "Locations");
            migrationBuilder.DropTable(
                name: "Regions");
        }
    }
}