using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace foodmarket.Infrastructure.Persistence.Migrations
{
    /// <summary>supplies.SupplierInvoiceNumber и SupplierInvoiceDate удалены.
    /// Решено что эти поля избыточны: дата документа уже есть в supplies.Date,
    /// а номер накладной поставщика всегда можно записать в Notes (примечание).</summary>
    public partial class Phase3b_DropSupplyInvoiceFields : Migration
    {
        protected override void Up(MigrationBuilder b)
        {
            b.DropColumn(name: "SupplierInvoiceDate", schema: "public", table: "supplies");
            b.DropColumn(name: "SupplierInvoiceNumber", schema: "public", table: "supplies");
        }

        protected override void Down(MigrationBuilder b)
        {
            b.AddColumn<System.DateTime>(
                name: "SupplierInvoiceDate", schema: "public", table: "supplies",
                type: "timestamp with time zone", nullable: true);
            b.AddColumn<string>(
                name: "SupplierInvoiceNumber", schema: "public", table: "supplies",
                type: "character varying(100)", maxLength: 100, nullable: true);
        }
    }
}
