using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace MyOffice.Migrations.Postgres.Migrations
{
///
public partial class AccountAccesUnique : Migration
{
///
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropIndex(
name: "IX_AccountAccesses_AccountId",
table: "AccountAccesses");
migrationBuilder.CreateIndex(
name: "IX_AccountAccesses_AccountId_UserId",
table: "AccountAccesses",
columns: new[] { "AccountId", "UserId" },
unique: true);
}
///
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropIndex(
name: "IX_AccountAccesses_AccountId_UserId",
table: "AccountAccesses");
migrationBuilder.CreateIndex(
name: "IX_AccountAccesses_AccountId",
table: "AccountAccesses",
column: "AccountId");
}
}
}