using System;
using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace RobotNet.ScriptManager.Data.Migrations
{
    /// <inheritdoc />
    public partial class InitScriptManagerDbContext : Migration
    {
        /// <inheritdoc />
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.CreateTable(
                name: "InstanceMissions",
                columns: table => new
                {
                    Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
                    MissionName = table.Column<string>(type: "varchar(126)", nullable: false),
                    CreatedAt = table.Column<DateTime>(type: "datetime2", nullable: false),
                    Status = table.Column<int>(type: "int", nullable: false),
                    Log = table.Column<string>(type: "nvarchar(max)", nullable: true)
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_InstanceMissions", x => x.Id);
                });

            migrationBuilder.CreateIndex(
                name: "IX_InstanceMissions_CreatedAt",
                table: "InstanceMissions",
                column: "CreatedAt");
        }

        /// <inheritdoc />
        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropTable(
                name: "InstanceMissions");
        }
    }
}
