Store round start date in the database (#21153)

This commit is contained in:
DrSmugleaf
2023-10-22 21:01:48 -07:00
committed by GitHub
parent 190b1f61f2
commit 43d5c00648
8 changed files with 3584 additions and 0 deletions

View File

@@ -0,0 +1,39 @@
#nullable disable
using System;
using Microsoft.EntityFrameworkCore.Migrations;
namespace Content.Server.Database.Migrations.Postgres
{
/// <inheritdoc />
public partial class RoundStartDate : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<DateTime>(
name: "start_date",
table: "round",
type: "timestamp with time zone",
nullable: false,
defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified));
migrationBuilder.CreateIndex(
name: "IX_round_start_date",
table: "round",
column: "start_date");
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropIndex(
name: "IX_round_start_date",
table: "round");
migrationBuilder.DropColumn(
name: "start_date",
table: "round");
}
}
}