using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace PARR.DAL.Migrations
{
    /// <inheritdoc />
    public partial class tblSettingsInitiatorUpdNagimovAndApplicationsUniqueTypeAndName : Migration
    {
        /// <inheritdoc />
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropIndex(
                name: "IX_Applications_Name",
                table: "Applications");

            migrationBuilder.UpdateData(
                table: "Settings",
                keyColumn: "Name",
                keyValue: "Initiator",
                column: "Value",
                value: "НАГИМОВ ПАВЕЛ БОРИСОВИЧ (5000966)");

            migrationBuilder.CreateIndex(
                name: "IX_Applications_Name_ApplicationTypeId",
                table: "Applications",
                columns: new[] { "Name", "ApplicationTypeId" },
                unique: true);
        }

        /// <inheritdoc />
        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropIndex(
                name: "IX_Applications_Name_ApplicationTypeId",
                table: "Applications");

            migrationBuilder.UpdateData(
                table: "Settings",
                keyColumn: "Name",
                keyValue: "Initiator",
                column: "Value",
                value: "КУЗНЕЦОВ МИХАИЛ ВАЛЕРЬЕВИЧ (IVC_KUZNETSOVMV@DVGD.OAO.RZD)");

            migrationBuilder.CreateIndex(
                name: "IX_Applications_Name",
                table: "Applications",
                column: "Name",
                unique: true);
        }
    }
}
