feat: item to collection
This commit is contained in:
@@ -77,6 +77,10 @@ namespace MemeVault.Infrastructure.Migrations
|
||||
.HasColumnType("character varying(500)")
|
||||
.HasColumnName("description");
|
||||
|
||||
b.Property<bool>("IsInbox")
|
||||
.HasColumnType("boolean")
|
||||
.HasColumnName("is_inbox");
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasMaxLength(100)
|
||||
@@ -101,10 +105,6 @@ namespace MemeVault.Infrastructure.Migrations
|
||||
.HasColumnType("text")
|
||||
.HasColumnName("visibility");
|
||||
|
||||
b.PrimitiveCollection<Guid[]>("_mediaItemIdsArray")
|
||||
.HasColumnType("uuid[]")
|
||||
.HasColumnName("media_item_ids");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("OwnerTelegramId")
|
||||
@@ -115,6 +115,11 @@ namespace MemeVault.Infrastructure.Migrations
|
||||
.HasDatabaseName("ix_collections_share_token")
|
||||
.HasFilter("share_token IS NOT NULL");
|
||||
|
||||
b.HasIndex("OwnerTelegramId", "IsInbox")
|
||||
.IsUnique()
|
||||
.HasDatabaseName("ix_collections_inbox_unique")
|
||||
.HasFilter("is_inbox = true");
|
||||
|
||||
b.ToTable("collections", (string)null);
|
||||
});
|
||||
|
||||
@@ -130,6 +135,10 @@ namespace MemeVault.Infrastructure.Migrations
|
||||
.HasColumnType("character varying(4096)")
|
||||
.HasColumnName("caption");
|
||||
|
||||
b.Property<Guid>("CollectionId")
|
||||
.HasColumnType("uuid")
|
||||
.HasColumnName("collection_id");
|
||||
|
||||
b.Property<DateTimeOffset>("CreatedAt")
|
||||
.HasColumnType("timestamp with time zone")
|
||||
.HasColumnName("created_at");
|
||||
@@ -159,6 +168,9 @@ namespace MemeVault.Infrastructure.Migrations
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("CollectionId")
|
||||
.HasDatabaseName("ix_media_items_collection");
|
||||
|
||||
b.HasIndex("OwnerTelegramId")
|
||||
.HasDatabaseName("ix_media_items_owner");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user