63 lines
2.4 KiB
C#
63 lines
2.4 KiB
C#
namespace Fitness_core_BE.DTOs.CustomerSubscription
|
|
{
|
|
/// <summary>Full picture of one subscription: plan config, members, money, schedule.</summary>
|
|
public class SubscriptionSummaryDto
|
|
{
|
|
public Guid SubscriptionId { get; set; }
|
|
public Guid CustomerPlanId { get; set; }
|
|
public string? PlanName { get; set; }
|
|
public string PlanScope { get; set; } = "Individual";
|
|
public int MemberLimit { get; set; } = 1;
|
|
public string DurationMode { get; set; } = "Rolling";
|
|
public bool AllowSplitPayments { get; set; }
|
|
public decimal PlanPrice { get; set; }
|
|
public DateTime OnboardDate { get; set; }
|
|
public DateTime? ExpiryDate { get; set; }
|
|
public DateTime? RenewalDate { get; set; }
|
|
public bool IsActive { get; set; }
|
|
|
|
public Guid? CustomerInvoiceId { get; set; }
|
|
public decimal InvoiceAmount { get; set; }
|
|
public decimal PaidAmount { get; set; }
|
|
public decimal Balance { get; set; }
|
|
public string PaymentStatus { get; set; } = "Pending";
|
|
|
|
public List<SubscriptionMemberDto> Members { get; set; } = new();
|
|
public List<SubscriptionInstallmentDto> Installments { get; set; } = new();
|
|
|
|
public bool AutoChargeEnabled { get; set; }
|
|
public AutoChargeCardDto? AutoChargeCard { get; set; }
|
|
}
|
|
|
|
public class AutoChargeCardDto
|
|
{
|
|
public Guid CardId { get; set; }
|
|
public string? CardLast4 { get; set; }
|
|
public string? CardType { get; set; }
|
|
}
|
|
|
|
public class SubscriptionMemberDto
|
|
{
|
|
public Guid SubscriptionMemberId { get; set; }
|
|
public Guid CustomerId { get; set; }
|
|
public string? CusName { get; set; }
|
|
public string? Email { get; set; }
|
|
public string? PrimaryPH { get; set; }
|
|
public bool IsPrimary { get; set; }
|
|
public DateTime JoinedAt { get; set; }
|
|
public bool IsActive { get; set; }
|
|
/// <summary>False when unassigned from the plan but still a member of the gym.</summary>
|
|
public bool IsPlanAssigned { get; set; } = true;
|
|
}
|
|
|
|
public class SubscriptionInstallmentDto
|
|
{
|
|
public Guid SubscriptionInstallmentId { get; set; }
|
|
public int InstallmentNo { get; set; }
|
|
public DateTime DueDate { get; set; }
|
|
public decimal Amount { get; set; }
|
|
public decimal PaidAmount { get; set; }
|
|
public string Status { get; set; } = "Pending";
|
|
}
|
|
}
|