Add customer communication system

This commit is contained in:
sysadmin
2025-08-27 18:02:39 +01:00
parent 1f7c0af497
commit eae5be3e7c
136 changed files with 14552 additions and 97 deletions

View File

@@ -6,8 +6,12 @@ namespace LittleShop.DTOs;
public class OrderDto
{
public Guid Id { get; set; }
public string IdentityReference { get; set; } = string.Empty;
public Guid? CustomerId { get; set; }
public string? IdentityReference { get; set; }
public OrderStatus Status { get; set; }
// Customer Information (embedded for convenience)
public CustomerSummaryDto? Customer { get; set; }
public decimal TotalAmount { get; set; }
public string Currency { get; set; } = "GBP";
public string ShippingName { get; set; } = string.Empty;
@@ -37,8 +41,13 @@ public class OrderItemDto
public class CreateOrderDto
{
[Required]
public string IdentityReference { get; set; } = string.Empty;
// Either Customer ID (for registered customers) OR Identity Reference (for anonymous)
public Guid? CustomerId { get; set; }
public string? IdentityReference { get; set; }
// Customer Information (collected at checkout for anonymous orders)
public CreateCustomerDto? CustomerInfo { get; set; }
[Required]
public string ShippingName { get; set; } = string.Empty;