Added missing fields to ModLogs entry

This commit is contained in:
Noikoio 2017-11-17 10:49:37 -08:00
parent 06e559b085
commit 5d5cdd9c84
2 changed files with 25 additions and 5 deletions

View file

@ -11,6 +11,7 @@ namespace Noikoio.RegexBot.Module.ModLogs
{
readonly int _logId;
readonly DateTime _ts;
readonly ulong _guildId;
readonly ulong? _invokeId;
readonly ulong _targetId;
readonly ulong? _channelId;
@ -26,15 +27,19 @@ namespace Noikoio.RegexBot.Module.ModLogs
/// </summary>
public DateTime Timestamp => _ts;
/// <summary>
/// Gets the ID of the invoking user.
/// This value exists only if this entry was created through action of another user that is not the target.
/// Gets the ID of the guild to which this log entry corresponds.
/// </summary>
public ulong? Invoker => _invokeId;
public ulong Guild => _guildId;
/// <summary>
/// Gets the ID of the user to which this log entry corresponds.
/// </summary>
public ulong Target => _targetId;
/// <summary>
/// Gets the ID of the invoking user.
/// This value exists only if this entry was created through action of another user that is not the target.
/// </summary>
public ulong? Invoker => _invokeId;
/// <summary>
/// Gets the guild channel ID to which this log entry corresponds, if any.
/// </summary>
public ulong? TargetChannel => _channelId;

View file

@ -1,13 +1,28 @@
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;
using Discord.WebSocket;
using Newtonsoft.Json.Linq;
namespace Noikoio.RegexBot.Module.ModLogs
{
/// <summary>
/// Listens for certain events and places them on the log.
/// Listens for Discord-based events and writes them to the log (database).
/// Additionally writes certain messages to a designated logging channel if configured.
/// </summary>
class EventListener
class EventListener : BotModule
{
public override string Name => "ModLogs";
public EventListener(DiscordSocketClient client) : base(client)
{
}
[ConfigSection("modlogs")]
public override Task<object> ProcessConfiguration(JToken configSection)
{
throw new NotImplementedException();
}
}
}