chat logs

This commit is contained in:
hydrant
2021-04-19 14:15:08 +02:00
parent f0b2eca560
commit 8485102e49
17 changed files with 2662 additions and 29 deletions

View File

@@ -0,0 +1,23 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public abstract class ChatLogEntry
{
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public long Id { get; set; }
[ForeignKey(nameof(UserId))]
public User User { get; set; }
public int UserId { get; set; }
public string Text { get; set; }
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public DateTime Time { get; set; }
}
}

View File

@@ -0,0 +1,10 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public class DepartmentChatLogEntry : ChatLogEntry
{
}
}

View File

@@ -0,0 +1,15 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public class FactionChatLogEntry : ChatLogEntry
{
[ForeignKey(nameof(Faction))]
public int FactionId { get; set; }
public Faction Faction { get; set; }
}
}

View File

@@ -0,0 +1,10 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public class GangChatLogEntry : ChatLogEntry
{
}
}

View File

@@ -0,0 +1,15 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public class GroupChatLogEntry : ChatLogEntry
{
public int GroupId { get; set; }
[ForeignKey(nameof(GroupId))]
public Group Group { get; set; }
}
}

View File

@@ -0,0 +1,10 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public class LeaderChatLogEntry : ChatLogEntry
{
}
}

View File

@@ -0,0 +1,10 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public class LocalChatLogEntry : ChatLogEntry
{
}
}

View File

@@ -0,0 +1,10 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public class NewsChatLogEntry : ChatLogEntry
{
}
}

View File

@@ -0,0 +1,10 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace ReallifeGamemode.Database.Entities.Logs.Chat
{
public class OChatLogEntry : ChatLogEntry
{
}
}