using CsvHelper.Configuration.Attributes; namespace PowderCoating.Application.DTOs.Import; /// /// DTO for importing invoice line items from CSV. Column names match the native /// invoice-items export (ExportInvoiceItemsCsv) for round-trip compatibility. /// Line items are matched to their parent invoice by InvoiceNumber; the revenue /// account is resolved from RevenueAccountNumber against Account.AccountNumber so the /// invoice's revenue attribution survives an export/import round-trip. /// public class InvoiceItemImportDto { [Name("InvoiceNumber")] public string? InvoiceNumber { get; set; } [Name("Description")] public string? Description { get; set; } [Name("Quantity")] public decimal Quantity { get; set; } [Name("UnitPrice")] public decimal UnitPrice { get; set; } [Name("TotalPrice")] public decimal TotalPrice { get; set; } [Name("ColorName")] public string? ColorName { get; set; } /// /// Account number (Chart of Accounts) of the revenue account this line posts to. Optional — /// a blank value means the line falls back to the company's default revenue account. /// [Name("RevenueAccountNumber")] public string? RevenueAccountNumber { get; set; } [Name("DisplayOrder")] public int DisplayOrder { get; set; } [Name("Notes")] public string? Notes { get; set; } }