first commit

This commit is contained in:
Dhananjaya99
2026-09-28 11:44:26 +05:30
parent 721743ae6b
commit bffc9b1686
424 changed files with 46474 additions and 0 deletions
+33
View File
@@ -0,0 +1,33 @@
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Fitness_core_BE.Models
{
public class CustomerInvoice
{
[Key]
public Guid CustomerInvoiceId { get; set; }
public Guid FKCustomerSubscriptionId { get; set; }
[ForeignKey("FKCustomerSubscriptionId")]
public virtual CustomerSubscription CustomerSubscription { get; set; }
public Guid FKClientId { get; set; }
[ForeignKey("FKClientId")]
public virtual Client Client { get; set; }
public Guid FKUserId { get; set; }
[ForeignKey("FKUserId")]
public virtual User User { get; set; }
public decimal Amount { get; set; }
public string Status { get; set; } = "Pending";
// Approval gate for the renewal workflow: false means this invoice was auto-generated by
// the daily renewal sweep and is awaiting staff approve/change-plan/reject. Independent of
// Status and of CustomerSubscription.IsActive. Defaults true so every other invoice-
// creation path (onboarding, plan change, manual billing) is unaffected.
public bool IsActive { get; set; } = true;
public DateTime CustomerInvoiceDate { get; set; } = DateTime.UtcNow;
}
}