Photo rendberakása + EF migráció

This commit is contained in:
2025-04-02 10:32:27 +02:00
parent fe7b52efde
commit 12bf69aadd
16 changed files with 1913 additions and 19 deletions
@@ -0,0 +1,58 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace WorkFlowCheck.DL.Migrations
{
/// <inheritdoc />
public partial class Extend012 : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "Photo",
table: "CheckListRow");
migrationBuilder.UpdateData(
table: "Users",
keyColumn: "Id",
keyValue: 1,
columns: new[] { "CreatedAt", "LastModAt" },
values: new object[] { new DateTime(2025, 4, 2, 8, 28, 48, 480, DateTimeKind.Utc).AddTicks(5537), new DateTime(2025, 4, 2, 8, 28, 48, 480, DateTimeKind.Utc).AddTicks(5540) });
migrationBuilder.UpdateData(
table: "Users",
keyColumn: "Id",
keyValue: 2,
columns: new[] { "CreatedAt", "LastModAt" },
values: new object[] { new DateTime(2025, 4, 2, 8, 28, 48, 491, DateTimeKind.Utc).AddTicks(9369), new DateTime(2025, 4, 2, 8, 28, 48, 491, DateTimeKind.Utc).AddTicks(9370) });
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<byte[]>(
name: "Photo",
table: "CheckListRow",
type: "varbinary(max)",
nullable: false,
defaultValue: new byte[0]);
migrationBuilder.UpdateData(
table: "Users",
keyColumn: "Id",
keyValue: 1,
columns: new[] { "CreatedAt", "LastModAt" },
values: new object[] { new DateTime(2025, 4, 1, 15, 16, 7, 535, DateTimeKind.Utc).AddTicks(5258), new DateTime(2025, 4, 1, 15, 16, 7, 535, DateTimeKind.Utc).AddTicks(5260) });
migrationBuilder.UpdateData(
table: "Users",
keyColumn: "Id",
keyValue: 2,
columns: new[] { "CreatedAt", "LastModAt" },
values: new object[] { new DateTime(2025, 4, 1, 15, 16, 7, 546, DateTimeKind.Utc).AddTicks(7925), new DateTime(2025, 4, 1, 15, 16, 7, 546, DateTimeKind.Utc).AddTicks(7926) });
}
}
}