fix(db): repair fresh migration chain
This commit is contained in:
@@ -11,6 +11,7 @@ namespace JobTrackerApi.Migrations
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
var mysql = ActiveProvider.Contains("MySql", StringComparison.OrdinalIgnoreCase);
|
||||
migrationBuilder.CreateTable(
|
||||
name: "Companies",
|
||||
columns: table => new
|
||||
@@ -39,7 +40,20 @@ namespace JobTrackerApi.Migrations
|
||||
ResponseDate = table.Column<DateTime>(type: "TEXT", nullable: true),
|
||||
Notes = table.Column<string>(type: "TEXT", nullable: true),
|
||||
CoverLetterText = table.Column<string>(type: "TEXT", nullable: true),
|
||||
JobUrl = table.Column<string>(type: "TEXT", nullable: true)
|
||||
JobUrl = table.Column<string>(type: "TEXT", nullable: true),
|
||||
// These stable columns predated EF ownership and were historically supplied by
|
||||
// startup reconciliation. Include them for new databases so the later SQLite
|
||||
// DateApplied rebuild has a complete source shape under standalone EF tooling.
|
||||
OwnerUserId = table.Column<string>(type: mysql ? "varchar(255)" : "TEXT", nullable: true),
|
||||
ShortSummary = table.Column<string>(type: mysql ? "longtext" : "TEXT", nullable: true),
|
||||
TailoredCvText = table.Column<string>(type: mysql ? "longtext" : "TEXT", nullable: true),
|
||||
TailoredCvUpdatedAt = table.Column<DateTime>(type: mysql ? "datetime(6)" : "TEXT", nullable: true),
|
||||
LastReminderEmailSentAt = table.Column<DateTime>(type: mysql ? "datetime(6)" : "TEXT", nullable: true),
|
||||
RecruiterMessageDraft = table.Column<string>(type: mysql ? "longtext" : "TEXT", nullable: true),
|
||||
SalaryMin = table.Column<decimal>(type: mysql ? "decimal(18,2)" : "TEXT", nullable: true),
|
||||
SalaryMax = table.Column<decimal>(type: mysql ? "decimal(18,2)" : "TEXT", nullable: true),
|
||||
SalaryCurrency = table.Column<string>(type: mysql ? "varchar(8)" : "TEXT", nullable: true),
|
||||
SalaryPeriod = table.Column<string>(type: mysql ? "varchar(16)" : "TEXT", nullable: true)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user