[CHANGE] Library service, db migrations, ui blazor

This commit is contained in:
max
2025-08-31 20:11:03 +02:00
parent aeb9adf930
commit 98fe4b9391
19 changed files with 1206 additions and 18 deletions

View File

@@ -32,17 +32,25 @@ public sealed class LibraryDbContext : DbContext
{
channel.ToTable("channels");
channel.HasKey(x => x.Id);
//TODO: Link media from channel
});
modelBuilder.Entity<ClientAccountEntity>(cae =>
{
cae.ToTable("client_accounts");
cae.HasKey(x => x.Id);
cae.HasMany(x => x.Playlists)
.WithOne()
.HasForeignKey(x => x.ChannelId);
cae.HasMany(x => x.HttpCookies)
.WithOne()
.HasForeignKey(x => x.ClientId);
});
modelBuilder.Entity<HttpCookieEntity>(httpce =>
{
httpce.ToTable("http_cookies");
httpce.HasKey(x => x.Name);
});
modelBuilder.Entity<MediaEntity>(me =>