90 lines
2.6 KiB
C#
90 lines
2.6 KiB
C#
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace Gready_Poang.DataLayer.Migrations
|
|
{
|
|
/// <inheritdoc />
|
|
public partial class statusfieldmove : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropColumn(
|
|
name: "PointStatus",
|
|
table: "GamePoints");
|
|
|
|
migrationBuilder.AddColumn<int>(
|
|
name: "GameStatus",
|
|
table: "GameRounds",
|
|
type: "INTEGER",
|
|
nullable: false,
|
|
defaultValue: 0);
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "GameRounds",
|
|
keyColumn: "GameRoundId",
|
|
keyValue: 1,
|
|
column: "GameStatus",
|
|
value: 0);
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "GameRounds",
|
|
keyColumn: "GameRoundId",
|
|
keyValue: 2,
|
|
column: "GameStatus",
|
|
value: 0);
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "GameRounds",
|
|
keyColumn: "GameRoundId",
|
|
keyValue: 3,
|
|
column: "GameStatus",
|
|
value: 0);
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropColumn(
|
|
name: "GameStatus",
|
|
table: "GameRounds");
|
|
|
|
migrationBuilder.AddColumn<int>(
|
|
name: "PointStatus",
|
|
table: "GamePoints",
|
|
type: "INTEGER",
|
|
nullable: false,
|
|
defaultValue: 0);
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "GamePoints",
|
|
keyColumn: "GamePointId",
|
|
keyValue: 1,
|
|
column: "PointStatus",
|
|
value: 0);
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "GamePoints",
|
|
keyColumn: "GamePointId",
|
|
keyValue: 2,
|
|
column: "PointStatus",
|
|
value: 0);
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "GamePoints",
|
|
keyColumn: "GamePointId",
|
|
keyValue: 3,
|
|
column: "PointStatus",
|
|
value: 0);
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "GamePoints",
|
|
keyColumn: "GamePointId",
|
|
keyValue: 4,
|
|
column: "PointStatus",
|
|
value: 0);
|
|
}
|
|
}
|
|
}
|