using System.ComponentModel.DataAnnotations.Schema;
namespace Distribution.Models
{
public class ShopPOItem : Template
{
public Guid FK_ShopPOId { get; set; }
[ForeignKey("FK_ShopPOId")]
public ShopPO ShopPO { get; set; }
public Guid FK_ItemId { get; set; }
[ForeignKey("FK_ItemId")]
public Item Item { get; set; }
public int Quantity { get; set; }
public int QuantityFulfilled { get; set; } = 0;
public decimal UnitPrice { get; set; }
/// Free issue granted by a scheme (UnitPrice 0); shown in the Free Issue column.
public bool IsFree { get; set; }
public Guid? FK_SchemeId { get; set; }
/// Scheme name when it was applied, so later scheme edits don't rewrite history.
public string? SchemeName { get; set; }
}
}