record-my-ruck/RecordMyRuck/Migrations/20240517025819_CreateRuck.cs

37 lines
1.1 KiB
C#
Raw Permalink Normal View History

2024-05-17 04:30:18 +00:00
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace RecordMyRuck.Migrations
{
/// <inheritdoc />
public partial class CreateRuck : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "Rucks",
columns: table => new
{
DateTime = table.Column<DateTime>(type: "TEXT", nullable: false),
Route = table.Column<string>(type: "TEXT", nullable: false),
WeightPounds = table.Column<float>(type: "REAL", nullable: false),
Notes = table.Column<string>(type: "TEXT", nullable: false)
},
constraints: table =>
{
table.PrimaryKey("PK_Rucks", x => x.DateTime);
});
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "Rucks");
}
}
}