feat: reorganized achevements queries and added client achievements request

This commit is contained in:
Mikhail Shabanov committed 2021-06-02 14:34:00 +02:00
1 parent 8da5bdbfa8
commit 11b8b15a2a
37 files changed
+1940 -781

No files matched your search

@@ -81,7 +81,7 @@ namespace WotBlitzStatisticsPro.Logic
var response = new AccountAchievementsResponse
{
AccountId = accountId,
AchievementSections = sections
Sections = sections
};
if (wgAchievements?.Achievements == null)
@@ -138,9 +138,9 @@ namespace WotBlitzStatisticsPro.Logic
}
// Sort achievements by sections
foreach (var section in response.AchievementSections)
foreach (var section in response.Sections)
{
section.Achievements = achievements.Where(a => a.SectionId == section.SectionId).ToList();
section.Medals = achievements.Where(a => a.SectionId == section.SectionId).ToList();
}
return response;