using System; using Microsoft.EntityFrameworkCore.Migrations; #nullable disable namespace DorkNet.Server.Migrations { /// public partial class Phase12Currency : Migration { /// protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.CreateTable( name: "CurrencyBalances", columns: table => new { Id = table.Column(type: "INTEGER", nullable: false) .Annotation("Sqlite:Autoincrement", true), PlayerId = table.Column(type: "INTEGER", nullable: false), CurrencyType = table.Column(type: "INTEGER", nullable: false), Balance = table.Column(type: "INTEGER", nullable: false), UpdatedAt = table.Column(type: "TEXT", nullable: false) }, constraints: table => { table.PrimaryKey("PK_CurrencyBalances", x => x.Id); }); migrationBuilder.CreateIndex( name: "IX_CurrencyBalances_PlayerId_CurrencyType", table: "CurrencyBalances", columns: new[] { "PlayerId", "CurrencyType" }, unique: true); } /// protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "CurrencyBalances"); } } }