1
0
mirror of https://github.com/RaidMax/IW4M-Admin.git synced 2025-06-11 07:40:54 -05:00

Using Code from EFPerformanceBucket for references

This commit is contained in:
Ayymoss
2024-09-07 18:41:18 +01:00
parent 79bd6ca8e1
commit 98e2be8623
17 changed files with 154 additions and 103 deletions

View File

@ -620,7 +620,7 @@ public class ZombieClientStateManager(
}
public async Task GetAdvancedStatsMetrics(Dictionary<int, List<EFMeta>> meta, long? serverId,
string performanceBucket,
string performanceBucketCode,
bool isTopStats)
{
if (isTopStats || !meta.Any())
@ -634,8 +634,8 @@ public class ZombieClientStateManager(
var iqStats = context.ZombieClientStatAggregates
.Where(stat => stat.ClientId == clientId);
iqStats = !string.IsNullOrEmpty(performanceBucket)
? iqStats.Where(stat => stat.Server.PerformanceBucket == performanceBucket)
iqStats = !string.IsNullOrEmpty(performanceBucketCode)
? iqStats.Where(stat => stat.Server.PerformanceBucket.Code == performanceBucketCode)
: iqStats.Where(stat => stat.ServerId == serverId);
var stats = await iqStats.Select(stat => new