faturas_4docs/Webhook 4docs/Migrations/20240321221626_InitialCreate.cs
2024-04-17 17:19:35 -03:00

39 lines
1.4 KiB
C#

using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable
namespace Webhook_4docs.Migrations
{
/// <inheritdoc />
public partial class InitialCreate : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "ProcessedInvoices",
columns: table => new
{
InvoiceId = table.Column<int>(type: "integer", nullable: false)
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
DateTimeProcessed = table.Column<DateTime>(type: "timestamp with time zone", nullable: false),
Status = table.Column<string>(type: "text", nullable: true),
InvoicePath = table.Column<string>(type: "text", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_ProcessedInvoices", x => x.InvoiceId);
});
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "ProcessedInvoices");
}
}
}