mirror of
https://github.com/DrMboga/WotBlitzStatisticsBlazor.git
synced 2026-10-24 03:40:07 +02:00
feat: deictionary query implemented
This commit is contained in:
1 parent
3e4f34ca16
commit
8a9f2f7077
21 files changed
+972
-69
No files matched your search
@@ -169,5 +169,13 @@ namespace WotBlitzStatisticsPro.DataAccess
|
||||
|
||||
return collection.ToDictionary(a => a.AchievementId, a => a);
|
||||
}
|
||||
|
||||
public async Task<List<IVehiclesDictionary>> GetVehiclesByNation(string nationId)
|
||||
{
|
||||
var collection = await _database.GetCollection<VehiclesDictionary>(VehiclesCollectionName)
|
||||
.Find(Builders<VehiclesDictionary>.Filter.Eq(v => v.NationId, nationId))
|
||||
.ToListAsync();
|
||||
return collection.Cast<IVehiclesDictionary>().ToList();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -37,5 +37,8 @@ namespace WotBlitzStatisticsPro.DataAccess
|
||||
Task<List<AchievementSectionDictionary>> GetAchievementSections();
|
||||
|
||||
Task<Dictionary<string, AchievementDictionary>> GetAchievements(string[] achievementIds);
|
||||
|
||||
Task<List<IVehiclesDictionary>> GetVehiclesByNation(string nationId);
|
||||
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user