SurveyVista/Web/Migrations/20260306033732_AddUserTrajectoryCache.cs
2026-03-07 02:37:33 +01:00

41 lines
1.6 KiB
C#

using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Web.Migrations
{
/// <inheritdoc />
public partial class AddUserTrajectoryCache : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "UserTrajectoryCaches",
columns: table => new
{
Id = table.Column<int>(type: "int", nullable: false)
.Annotation("SqlServer:Identity", "1, 1"),
UserEmail = table.Column<string>(type: "nvarchar(256)", maxLength: 256, nullable: false),
AnalyzedResponseCount = table.Column<int>(type: "int", nullable: false),
LastResponseDate = table.Column<DateTime>(type: "datetime2", nullable: false),
TrajectoryJson = table.Column<string>(type: "nvarchar(max)", nullable: false),
PreviousSummary = table.Column<string>(type: "nvarchar(max)", nullable: true),
CreatedAt = table.Column<DateTime>(type: "datetime2", nullable: false),
UpdatedAt = table.Column<DateTime>(type: "datetime2", nullable: false)
},
constraints: table =>
{
table.PrimaryKey("PK_UserTrajectoryCaches", x => x.Id);
});
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "UserTrajectoryCaches");
}
}
}