using Microsoft.EntityFrameworkCore.Migrations; #nullable disable namespace Infrastructure.Migrations.AppDb { /// public partial class AddCrewInviteCode : Migration { /// protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.AddColumn( name: "InviteCode", table: "Crew", type: "nvarchar(8)", maxLength: 8, nullable: true); migrationBuilder.CreateIndex( name: "IX_Crew_InviteCode", table: "Crew", column: "InviteCode", unique: true, filter: "[InviteCode] IS NOT NULL"); } /// protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropIndex( name: "IX_Crew_InviteCode", table: "Crew"); migrationBuilder.DropColumn( name: "InviteCode", table: "Crew"); } } }