Add switch commands for adding and moving

This commit is contained in:
Ske
2019-06-13 16:53:04 +02:00
parent 4c6790432b
commit 7e9b7dcc98
7 changed files with 302 additions and 10 deletions

View File

@@ -1,11 +1,9 @@
using System;
using Dapper.Contrib.Extensions;
using NodaTime;
using NodaTime.Text;
namespace PluralKit
{
[Table("systems")]
public class PKSystem
{
[Key]
@@ -22,7 +20,6 @@ namespace PluralKit
public int MaxMemberNameLength => Tag != null ? 32 - Tag.Length - 1 : 32;
}
[Table("members")]
public class PKMember
{
public int Id { get; set; }
@@ -54,4 +51,18 @@ namespace PluralKit
public bool HasProxyTags => Prefix != null || Suffix != null;
public string ProxyString => $"{Prefix ?? ""}text{Suffix ?? ""}";
}
public class PKSwitch
{
public int Id { get; set; }
public int System { get; set; }
public Instant Timestamp { get; set; }
}
public class PKSwitchMember
{
public int Id { get; set; }
public int Switch { get; set; }
public int Member { get; set; }
}
}