Fix bot TOP 3

This commit is contained in:
2025-09-25 11:08:28 +07:00
parent 253c448acb
commit c297429b18
7 changed files with 128 additions and 30 deletions

View File

@@ -37,4 +37,20 @@ public interface IBotRepository
string? agentName = null,
string sortBy = "CreateDate",
string sortDirection = "Desc");
/// <summary>
/// Gets the top performing bots by PnL from the specified statuses
/// </summary>
/// <param name="statuses">Bot statuses to include in the query</param>
/// <param name="count">Number of top performers to return (default: 3)</param>
/// <returns>Top performing bots ordered by PnL descending</returns>
Task<IEnumerable<Bot>> GetTopBotsByPnLAsync(IEnumerable<BotStatus> statuses, int count = 3);
/// <summary>
/// Gets the top performing bots by ROI from the specified statuses
/// </summary>
/// <param name="statuses">Bot statuses to include in the query</param>
/// <param name="count">Number of top performers to return (default: 3)</param>
/// <returns>Top performing bots ordered by ROI descending</returns>
Task<IEnumerable<Bot>> GetTopBotsByRoiAsync(IEnumerable<BotStatus> statuses, int count = 3);
}