diff --git a/bitwarden_license/src/Commercial.Core/Billing/Models/ProviderClientInvoiceReportRow.cs b/bitwarden_license/src/Commercial.Core/Billing/Models/ProviderClientInvoiceReportRow.cs index 5256d11a6c..aaf04f6030 100644 --- a/bitwarden_license/src/Commercial.Core/Billing/Models/ProviderClientInvoiceReportRow.cs +++ b/bitwarden_license/src/Commercial.Core/Billing/Models/ProviderClientInvoiceReportRow.cs @@ -1,5 +1,6 @@ using System.Globalization; using Bit.Core.Billing.Entities; +using CsvHelper.Configuration.Attributes; namespace Bit.Commercial.Core.Billing.Models; @@ -10,6 +11,7 @@ public class ProviderClientInvoiceReportRow public int Used { get; set; } public int Remaining { get; set; } public string Plan { get; set; } + [Name("Estimated total")] public string Total { get; set; } public static ProviderClientInvoiceReportRow From(ProviderInvoiceItem providerInvoiceItem) diff --git a/src/Api/Billing/Models/Responses/InvoicesResponse.cs b/src/Api/Billing/Models/Responses/InvoicesResponse.cs index f9ab2a4ae5..384b2fdd76 100644 --- a/src/Api/Billing/Models/Responses/InvoicesResponse.cs +++ b/src/Api/Billing/Models/Responses/InvoicesResponse.cs @@ -19,8 +19,7 @@ public record InvoiceDTO( decimal Total, string Status, DateTime? DueDate, - string Url, - string PdfUrl) + string Url) { public static InvoiceDTO From(Invoice invoice) => new( invoice.Id, @@ -29,6 +28,5 @@ public record InvoiceDTO( invoice.Total / 100M, invoice.Status, invoice.DueDate, - invoice.HostedInvoiceUrl, - invoice.InvoicePdf); + invoice.HostedInvoiceUrl); } diff --git a/test/Api.Test/Billing/Controllers/ProviderBillingControllerTests.cs b/test/Api.Test/Billing/Controllers/ProviderBillingControllerTests.cs index 2c4245bd64..acd6721a50 100644 --- a/test/Api.Test/Billing/Controllers/ProviderBillingControllerTests.cs +++ b/test/Api.Test/Billing/Controllers/ProviderBillingControllerTests.cs @@ -92,7 +92,6 @@ public class ProviderBillingControllerTests Assert.Equal(1000, openInvoice.Total); Assert.Equal(new DateTime(2024, 7, 1), openInvoice.DueDate); Assert.Equal("https://example.com/invoice/2", openInvoice.Url); - Assert.Equal("https://example.com/invoice/2/pdf", openInvoice.PdfUrl); var paidInvoice = response.Invoices.FirstOrDefault(i => i.Status == "paid"); @@ -103,7 +102,6 @@ public class ProviderBillingControllerTests Assert.Equal(1000, paidInvoice.Total); Assert.Equal(new DateTime(2024, 6, 1), paidInvoice.DueDate); Assert.Equal("https://example.com/invoice/1", paidInvoice.Url); - Assert.Equal("https://example.com/invoice/1/pdf", paidInvoice.PdfUrl); } #endregion