mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-06-24 07:51:28 +00:00
Serialize SlotType with Slot API responses
This commit is contained in:
parent
9b7924cd07
commit
fc522b33a4
2 changed files with 6 additions and 0 deletions
|
@ -1,5 +1,6 @@
|
|||
using LBPUnion.ProjectLighthouse.Database;
|
||||
using LBPUnion.ProjectLighthouse.Types.Entities.Level;
|
||||
using LBPUnion.ProjectLighthouse.Types.Levels;
|
||||
using LBPUnion.ProjectLighthouse.Types.Misc;
|
||||
using LBPUnion.ProjectLighthouse.Types.Users;
|
||||
using Newtonsoft.Json;
|
||||
|
@ -11,6 +12,7 @@ public struct ApiSlot
|
|||
{
|
||||
public int SlotId { get; set; }
|
||||
public int InternalSlotId { get; set; }
|
||||
public SlotType Type { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string Description { get; set; }
|
||||
public string IconHash { get; set; }
|
||||
|
@ -42,6 +44,7 @@ public struct ApiSlot
|
|||
{
|
||||
SlotId = slot.SlotId,
|
||||
InternalSlotId = slot.InternalSlotId,
|
||||
Type = slot.Type,
|
||||
Name = slot.Name,
|
||||
Description = slot.Description,
|
||||
IconHash = slot.IconHash,
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
using LBPUnion.ProjectLighthouse.Types.Entities.Level;
|
||||
using LBPUnion.ProjectLighthouse.Types.Levels;
|
||||
using LBPUnion.ProjectLighthouse.Types.Misc;
|
||||
using LBPUnion.ProjectLighthouse.Types.Users;
|
||||
using Newtonsoft.Json;
|
||||
|
@ -9,6 +10,7 @@ namespace LBPUnion.ProjectLighthouse.Servers.API.Responses;
|
|||
public struct MinimalApiSlot
|
||||
{
|
||||
public int SlotId { get; set; }
|
||||
public SlotType Type { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string IconHash { get; set; }
|
||||
public bool TeamPick { get; set; }
|
||||
|
@ -26,6 +28,7 @@ public struct MinimalApiSlot
|
|||
new()
|
||||
{
|
||||
SlotId = slot.SlotId,
|
||||
Type = slot.Type,
|
||||
Name = slot.Name,
|
||||
IconHash = slot.IconHash,
|
||||
TeamPick = slot.TeamPick,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue