Added Thumbnail Mirgration

This commit is contained in:
PascalMarchesseault
2024-11-23 10:51:45 -05:00
parent fcb7ad0c47
commit 502ca0313a
3 changed files with 7 additions and 2 deletions

View File

@@ -11,8 +11,8 @@ public class Content
public Guid? DeletedBy { get; set; } public Guid? DeletedBy { get; set; }
public DateTimeOffset? DeletedAt { get; set; } public DateTimeOffset? DeletedAt { get; set; }
[MaxLength(128)] public required string Title { get; set; } [MaxLength(128)] public required string Title { get; set; }
[MaxLength(512)]public string? ThumbnailUrl { get; init; } [MaxLength(512)] public string? ThumbnailUrl { get; set; } = "";
[MaxLength(2048)] public string Description { get; set; } = ""; [MaxLength(2048)] public string Description { get; set; } = "";
[MaxLength(2048)] public string? HtmlFileUrl { get; set; } = ""; [MaxLength(2048)] public string? HtmlFileUrl { get; set; } = "";
public IList<ContentReaction> Reactions { get; set; } = new List<ContentReaction>(); public IList<ContentReaction> Reactions { get; set; } = new List<ContentReaction>();

View File

@@ -52,6 +52,10 @@ namespace Hutopy.Web.Features.Contents.Data.Migrations
.HasMaxLength(2048) .HasMaxLength(2048)
.HasColumnType("character varying(2048)"); .HasColumnType("character varying(2048)");
b.Property<string>("ThumbnailUrl")
.HasMaxLength(512)
.HasColumnType("character varying(512)");
b.Property<string>("Title") b.Property<string>("Title")
.IsRequired() .IsRequired()
.HasMaxLength(128) .HasMaxLength(128)

View File

@@ -33,6 +33,7 @@
<Folder Include="Features\Contents\Data\Migrations\" /> <Folder Include="Features\Contents\Data\Migrations\" />
<Folder Include="Features\Memberships\Data\Migrations\" /> <Folder Include="Features\Memberships\Data\Migrations\" />
<Folder Include="Features\Users\Data\Migrations\" /> <Folder Include="Features\Users\Data\Migrations\" />
<Folder Include="Migrations\" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>