1
0
mirror of https://github.com/bitwarden/server synced 2025-12-25 20:53:16 +00:00
Files
server/src/Core/Billing/Entities/ProviderInvoiceItem.cs
Alex Morask 9c8a9f41fb [AC-2804] Add client ID to provider client invoice report (#4458)
* Add client ID to provider client invoice report

* Run dotnet format
2024-07-05 10:12:03 -04:00

35 lines
922 B
C#

using System.ComponentModel.DataAnnotations;
using Bit.Core.Entities;
using Bit.Core.Utilities;
#nullable enable
namespace Bit.Core.Billing.Entities;
public class ProviderInvoiceItem : ITableObject<Guid>
{
public Guid Id { get; set; }
public Guid ProviderId { get; set; }
[MaxLength(50)]
public string InvoiceId { get; set; } = null!;
[MaxLength(50)]
public string? InvoiceNumber { get; set; }
public Guid? ClientId { get; set; }
[MaxLength(50)]
public string ClientName { get; set; } = null!;
[MaxLength(50)]
public string PlanName { get; set; } = null!;
public int AssignedSeats { get; set; }
public int UsedSeats { get; set; }
public decimal Total { get; set; }
public DateTime Created { get; set; } = DateTime.UtcNow;
public void SetNewId()
{
if (Id == default)
{
Id = CoreHelpers.GenerateComb();
}
}
}