#nullable disable using System; using Microsoft.EntityFrameworkCore.Migrations; namespace Content.Server.Database.Migrations.Postgres { /// public partial class RoleWhitelist : Migration { /// protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.CreateTable( name: "role_whitelists", columns: table => new { player_user_id = table.Column(type: "uuid", nullable: false), role_id = table.Column(type: "text", nullable: false) }, constraints: table => { table.PrimaryKey("PK_role_whitelists", x => new { x.player_user_id, x.role_id }); table.ForeignKey( name: "FK_role_whitelists_player_player_user_id", column: x => x.player_user_id, principalTable: "player", principalColumn: "user_id", onDelete: ReferentialAction.Cascade); }); } /// protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "role_whitelists"); } } }