Files
SVSimServer/SVSim.Database/Models/ViewerFriendApply.cs
gamer147 1813217c16 feat(friend): add ViewerFriend + ViewerFriendApply + ViewerPlayedTogether entities
Lays the persistence foundation for the /friend/* API surface. Three new
model classes with composite PKs / unique constraints / FK cascades registered
on SVSimDbContext; 4/4 persistence tests pass on SQLite in-memory.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-09 21:40:08 -04:00

18 lines
661 B
C#

namespace SVSim.Database.Models;
/// <summary>
/// One pending friend application. <see cref="Id"/> is the wire <c>apply_id</c>
/// (auto-generated). Unique on <c>(FromViewerId, ToViewerId)</c> — a viewer can only
/// have one outstanding apply to any given target.
/// </summary>
public class ViewerFriendApply
{
public int Id { get; set; }
public long FromViewerId { get; set; }
public long ToViewerId { get; set; }
public DateTime CreatedAt { get; set; }
/// <summary>Beginner-friend campaign tag. Defaults to 0 (no campaign). Surfaces as optional <c>mission_type</c> on the wire.</summary>
public int MissionType { get; set; }
}