docker files fixes from liaqat
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
using Discord.WebSocket;
|
||||
using Managing.Application.Workers.Abstractions;
|
||||
|
||||
namespace Managing.Infrastructure.Messengers.Discord;
|
||||
|
||||
public static class SlashCommands
|
||||
{
|
||||
public static async Task HandleLeaderboardCommand(IServiceProvider service, SocketSlashCommand command)
|
||||
{
|
||||
var statisticService = (IStatisticService)service.GetService(typeof(IStatisticService));
|
||||
var traders = statisticService.GetBestTraders();
|
||||
await command.FollowupAsync(embed: DiscordHelpers.GetTradersEmbed(traders, "Leaderboard"), ephemeral: true);
|
||||
}
|
||||
|
||||
public static async Task HandleNoobiesboardCommand(IServiceProvider service, SocketSlashCommand command)
|
||||
{
|
||||
var statisticService = (IStatisticService)service.GetService(typeof(IStatisticService));
|
||||
var traders = statisticService.GetBadTraders();
|
||||
await command.FollowupAsync(embed: DiscordHelpers.GetTradersEmbed(traders, "Noobiesboard"), ephemeral: true);
|
||||
}
|
||||
|
||||
public static async Task HandleLeadboardPositionCommand(IServiceProvider service, SocketSlashCommand command)
|
||||
{
|
||||
var statisticService = (IStatisticService)service.GetService(typeof(IStatisticService));
|
||||
var trades = await statisticService.GetLeadboardPositons();
|
||||
await command.FollowupAsync(embed: DiscordHelpers.GetTradesEmbed(trades, "Leaderboard Open position"), ephemeral: true);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user