using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Hutopy.Modules.Tipping.Migrations
{
///
public partial class Initial : Migration
{
///
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.EnsureSchema(
name: "Tipping");
migrationBuilder.CreateTable(
name: "Tips",
schema: "Tipping",
columns: table => new
{
Id = table.Column(type: "uuid", nullable: false),
CreatorId = table.Column(type: "uuid", nullable: false),
Status = table.Column(type: "smallint", nullable: false),
Amount = table.Column(type: "numeric", nullable: false),
Currency = table.Column(type: "text", nullable: false),
Message = table.Column(type: "text", nullable: false),
StripeSessionId = table.Column(type: "text", nullable: false),
StripeInvoiceUrl = table.Column(type: "text", nullable: true),
CreatedBy = table.Column(type: "uuid", nullable: false),
CreatedAt = table.Column(type: "timestamp with time zone", nullable: false, defaultValueSql: "CURRENT_TIMESTAMP"),
DeletedBy = table.Column(type: "uuid", nullable: true),
DeletedAt = table.Column(type: "timestamp with time zone", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Tips", x => x.Id);
});
}
///
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "Tips",
schema: "Tipping");
}
}
}