Added more UI styling. Updated voice work search provider to send back English tag names, if applicable.
All checks were successful
ci / build-test (push) Successful in 2m15s
ci / publish-image (push) Has been skipped

This commit is contained in:
2025-11-15 22:37:15 -05:00
parent 634050c06f
commit 75900a90ef
10 changed files with 245 additions and 12 deletions

View File

@@ -388,16 +388,18 @@ public class VoiceWorkSearchProvider(AppDbContext context, IVoiceWorkFullTextSea
var tagRows = await (
from voiceWorkTag in context.VoiceWorkTags.AsNoTracking()
join tag in context.Tags.AsNoTracking() on voiceWorkTag.TagId equals tag.TagId
join englishTag in context.EnglishTags.AsNoTracking() on tag.TagId equals englishTag.TagId into et
from englishTag in et.DefaultIfEmpty()
where voiceWorkIds.Contains(voiceWorkTag.VoiceWorkId)
orderby voiceWorkTag.VoiceWorkId, voiceWorkTag.Position
select new { voiceWorkTag.VoiceWorkId, voiceWorkTag.TagId, tag.Name }
select new { voiceWorkTag.VoiceWorkId, voiceWorkTag.TagId, tag.Name, EnglishName = englishTag.Name }
).ToListAsync(cancellationToken);
return tagRows
.GroupBy(r => r.VoiceWorkId)
.ToDictionary(
g => g.Key,
g => g.Select(r => new VoiceWorkTagItem { TagId = r.TagId, Name = r.Name }).ToArray()
g => g.Select(r => new VoiceWorkTagItem { TagId = r.TagId, Name = r.EnglishName ?? r.Name }).ToArray()
);
}