using FruitBank.Common.Dtos; using FruitBank.Common.Interfaces; using Nop.Web.Framework.Models; using Nop.Web.Framework.Mvc.ModelBinding; namespace Nop.Plugin.Misc.FruitBankPlugin.Models.Orders { public record OrderAttributesModel : BaseNopModel, IMeasurable { public int OrderId { get; set; } [NopResourceDisplayName("Plugins.YourCompany.ProductAttributes.Fields.IsMeasurable")] public bool IsMeasurable { get; set; } [NopResourceDisplayName("Plugins.YourCompany.ProductAttributes.Fields.DateOfReceipt")] public DateTime? DateOfReceipt { get; set; } public OrderDto OrderDto { get; set; } // ── Site (telephely) + license plate (rendszám) ──────────────────────── public int CustomerId { get; set; } /// The order's current frozen site snapshot, if any. public OrderSiteSnapshot? Site { get; set; } public string? LicensePlate { get; set; } /// The customer's current sites — choices for the order-site selector. public List CustomerSites { get; set; } = new(); /// The customer's saved license plates — suggestions (datalist) for the order plate field. public List CustomerLicensePlateOptions { get; set; } = new(); } public class OrderSiteOption { public int AddressId { get; set; } public string Display { get; set; } = string.Empty; public bool IsDefault { get; set; } } }