45 lines
1.6 KiB
C#
45 lines
1.6 KiB
C#
|
using System;
|
|||
|
using Microsoft.EntityFrameworkCore.Metadata;
|
|||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|||
|
|
|||
|
#nullable disable
|
|||
|
|
|||
|
namespace EllieBot.Migrations.Mysql
|
|||
|
{
|
|||
|
public partial class gamblingstats : Migration
|
|||
|
{
|
|||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|||
|
{
|
|||
|
migrationBuilder.CreateTable(
|
|||
|
name: "gamblingstats",
|
|||
|
columns: table => new
|
|||
|
{
|
|||
|
id = table.Column<int>(type: "int", nullable: false)
|
|||
|
.Annotation("MySql:ValueGenerationStrategy", MySqlValueGenerationStrategy.IdentityColumn),
|
|||
|
feature = table.Column<string>(type: "varchar(255)", nullable: true)
|
|||
|
.Annotation("MySql:CharSet", "utf8mb4"),
|
|||
|
bet = table.Column<decimal>(type: "decimal(65,30)", nullable: false),
|
|||
|
paidout = table.Column<decimal>(type: "decimal(65,30)", nullable: false),
|
|||
|
dateadded = table.Column<DateTime>(type: "datetime(6)", nullable: true)
|
|||
|
},
|
|||
|
constraints: table =>
|
|||
|
{
|
|||
|
table.PrimaryKey("pk_gamblingstats", x => x.id);
|
|||
|
})
|
|||
|
.Annotation("MySql:CharSet", "utf8mb4");
|
|||
|
|
|||
|
migrationBuilder.CreateIndex(
|
|||
|
name: "ix_gamblingstats_feature",
|
|||
|
table: "gamblingstats",
|
|||
|
column: "feature",
|
|||
|
unique: true);
|
|||
|
}
|
|||
|
|
|||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|||
|
{
|
|||
|
migrationBuilder.DropTable(
|
|||
|
name: "gamblingstats");
|
|||
|
}
|
|||
|
}
|
|||
|
}
|