btcpayserver/BTCPayServer.Data/Migrations/20211021085011_RemovePayoutDestinationConstraint.cs

42 lines
1.3 KiB
C#
Raw Normal View History

// <auto-generated />
using System;
using BTCPayServer.Data;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
namespace BTCPayServer.Migrations
{
[DbContext(typeof(ApplicationDbContext))]
[Migration("20211021085011_RemovePayoutDestinationConstraint")]
public partial class RemovePayoutDestinationConstraint : Migration
{
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropIndex(
name: "IX_Payouts_Destination",
table: "Payouts");
migrationBuilder.CreateIndex(
name: "IX_Payouts_Destination_State",
table: "Payouts",
columns: new[] { "Destination", "State" });
}
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropIndex(
name: "IX_Payouts_Destination_State",
table: "Payouts");
migrationBuilder.CreateIndex(
name: "IX_Payouts_Destination",
table: "Payouts",
column: "Destination",
unique: true);
}
}
}