git-subtree-dir: backend git-subtree-mainline:ab911955edgit-subtree-split:040cfd7a75
60 lines
3.4 KiB
C#
60 lines
3.4 KiB
C#
using System;
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace Hutopy.Web.Features.Contents.Data.Migrations
|
|
{
|
|
/// <inheritdoc />
|
|
public partial class AddPresentationInfos : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.CreateTable(
|
|
name: "PresentationInfos",
|
|
schema: "Content",
|
|
columns: table => new
|
|
{
|
|
CreatorId = table.Column<Guid>(type: "uuid", nullable: false),
|
|
PhoneNumber = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
Email = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
Title = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
MainImageUrl = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
MainImageText = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
MainVideoText = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
ImagesSubtitle = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
Image1Url = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
Image2Url = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
Image3Url = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
Image4Url = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
ImagesText = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
VideoSubtitle = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
VideoSubtitleMain = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
VideoUrlMain = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
VideoUrl = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false),
|
|
VideoText = table.Column<string>(type: "character varying(255)", maxLength: 255, nullable: false)
|
|
},
|
|
constraints: table =>
|
|
{
|
|
table.PrimaryKey("PK_PresentationInfos", x => x.CreatorId);
|
|
table.ForeignKey(
|
|
name: "FK_PresentationInfos_Creators_CreatorId",
|
|
column: x => x.CreatorId,
|
|
principalSchema: "Content",
|
|
principalTable: "Creators",
|
|
principalColumn: "Id",
|
|
onDelete: ReferentialAction.Cascade);
|
|
});
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropTable(
|
|
name: "PresentationInfos",
|
|
schema: "Content");
|
|
}
|
|
}
|
|
}
|