Files
Watcher/watcher-monitoring/Migrations/20260107110229_servermetadata.cs
triggermeelmo f09434d66d
Some checks failed
Gitea CI/CD / dotnet-build-and-test (push) Failing after 38s
Gitea CI/CD / Set Tag Name (push) Has been skipped
Gitea CI/CD / docker-build-and-push (push) Has been skipped
Gitea CI/CD / Create Tag (push) Has been skipped
test
2026-01-07 12:47:23 +01:00

64 lines
1.8 KiB
C#

using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace watcher_monitoring.Migrations
{
/// <inheritdoc />
public partial class servermetadata : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<DateTime>(
name: "CreatedAt",
table: "Servers",
type: "TEXT",
nullable: false,
defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified));
migrationBuilder.AddColumn<bool>(
name: "IsOnline",
table: "Servers",
type: "INTEGER",
nullable: false,
defaultValue: false);
migrationBuilder.AddColumn<bool>(
name: "IsVerified",
table: "Servers",
type: "INTEGER",
nullable: false,
defaultValue: false);
migrationBuilder.AddColumn<DateTime>(
name: "LastSeen",
table: "Servers",
type: "TEXT",
nullable: false,
defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified));
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "CreatedAt",
table: "Servers");
migrationBuilder.DropColumn(
name: "IsOnline",
table: "Servers");
migrationBuilder.DropColumn(
name: "IsVerified",
table: "Servers");
migrationBuilder.DropColumn(
name: "LastSeen",
table: "Servers");
}
}
}