45 lines
1.2 KiB
C#
45 lines
1.2 KiB
C#
using CsvHelper.Configuration.Attributes;
|
|
|
|
namespace PowderCoating.Application.DTOs.Import;
|
|
|
|
/// <summary>
|
|
/// DTO for importing purchase order headers from CSV. Column names match the native
|
|
/// ExportPurchaseOrdersCsv output for round-trip compatibility. Upsert key is PoNumber.
|
|
/// </summary>
|
|
public class PurchaseOrderImportDto
|
|
{
|
|
[Name("PoNumber")]
|
|
public string? PoNumber { get; set; }
|
|
|
|
/// <summary>Vendor company name — must match an existing vendor record.</summary>
|
|
[Name("Vendor")]
|
|
public string? Vendor { get; set; }
|
|
|
|
/// <summary>
|
|
/// Valid values: Draft, Submitted, PartiallyReceived, Received, Cancelled
|
|
/// </summary>
|
|
[Name("Status")]
|
|
public string Status { get; set; } = "Draft";
|
|
|
|
[Name("OrderDate")]
|
|
public DateTime OrderDate { get; set; }
|
|
|
|
[Name("ExpectedDeliveryDate")]
|
|
public DateTime? ExpectedDeliveryDate { get; set; }
|
|
|
|
[Name("ReceivedDate")]
|
|
public DateTime? ReceivedDate { get; set; }
|
|
|
|
[Name("SubTotal")]
|
|
public decimal SubTotal { get; set; }
|
|
|
|
[Name("ShippingCost")]
|
|
public decimal ShippingCost { get; set; }
|
|
|
|
[Name("TotalAmount")]
|
|
public decimal TotalAmount { get; set; }
|
|
|
|
[Name("Notes")]
|
|
public string? Notes { get; set; }
|
|
}
|