docs: fix for TOC generation appsettings.json : local
This commit is contained in:
parent
96406b3777
commit
4558de6d7d
@ -8,8 +8,8 @@
|
||||
},
|
||||
"AllowedHosts": "*",
|
||||
"GoogleAnalyticsCode": "",
|
||||
"APIRoot": "https://api.ganjoor.net",
|
||||
"GlobalAPIRoot": "https://api.ganjoor.net",
|
||||
"APIRoot": "http://localhost:3439",
|
||||
"GlobalAPIRoot": "http://localhost:3439",
|
||||
"SiteUrl": "http://localhost:33081",
|
||||
"MockSpotify": "False",
|
||||
"Spotify": {
|
||||
|
||||
@ -348,6 +348,17 @@ namespace RMuseum.Services.Implementation
|
||||
html += $"</div>{Environment.NewLine}";
|
||||
}
|
||||
|
||||
var poemIds = poems.Select(p => p.Id).ToArray();
|
||||
|
||||
var mainPoemSections = await context.GanjoorPoemSections.Where(s => poemIds.Contains(s.PoemId) && s.SectionType == PoemSectionType.WholePoem && s.VerseType == VersePoemSectionType.First).ToListAsync();
|
||||
|
||||
foreach (var poem in poems)
|
||||
{
|
||||
var section = mainPoemSections.Where(s => s.PoemId == poem.Id).FirstOrDefault();
|
||||
if (section != null)
|
||||
poem.RhymeLetters = section.RhymeLetters;
|
||||
}
|
||||
|
||||
if (poems.Count > 0)
|
||||
{
|
||||
if (options == GanjoorTOC.Analyse)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user