using ROLAC.API.Entities.Base;
namespace ROLAC.API.Entities;

/// <summary>
/// A 1099 recipient (independent contractor / vendor). Holds W-9 data and an encrypted TIN.
/// Optionally linked to a Member (e.g. a part-time co-worker paid as a contractor).
/// </summary>
public class Payee1099 : SoftDeleteEntity, IAuditable
{
    public int     Id                { get; set; }
    public string  LegalName         { get; set; } = null!;     // name on the W-9
    public string? DisplayName       { get; set; }              // friendly / DBA
    public int?    MemberId          { get; set; }
    public Member? Member            { get; set; }
    public string  TaxClassification { get; set; } = "Individual"; // drives Is1099Tracked default
    public bool    Is1099Tracked     { get; set; } = true;
    public string? TinType           { get; set; }              // "SSN" | "EIN"
    public string? TinEncrypted      { get; set; }              // Data-Protection ciphertext
    public string? TinLast4          { get; set; }
    public string? AddressLine1      { get; set; }
    public string? AddressLine2      { get; set; }
    public string? City              { get; set; }
    public string? State             { get; set; }
    public string? Zip               { get; set; }
    public string? Email             { get; set; }
    public string? Phone             { get; set; }
    public string  W9Status          { get; set; } = Form1099.W9Status.Missing;
    public DateOnly? W9ReceivedDate  { get; set; }
    public string? W9BlobPath        { get; set; }
    public bool    IsActive          { get; set; } = true;
    public string? Notes             { get; set; }
}
