31 lines
978 B
C#
31 lines
978 B
C#
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
namespace ChaosBot.Migrations
|
|
{
|
|
public partial class Points : Migration
|
|
{
|
|
private const string Table = "Points";
|
|
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.CreateTable(
|
|
name: Table,
|
|
columns: table => new
|
|
{
|
|
DiscordUserId = table.Column<ulong>(nullable: false),
|
|
DiscordGuildId = table.Column<ulong>(nullable: false),
|
|
Amount = table.Column<ulong>(nullable: false, defaultValue: 0)
|
|
},
|
|
constraints: table =>
|
|
{
|
|
table.PrimaryKey("PK_UserAndServer", x => new {x.DiscordUserId, x.DiscordGuildId});
|
|
});
|
|
}
|
|
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropTable(Table);
|
|
}
|
|
}
|
|
}
|