diff --git a/ComputerShopProvider/ComputerShopContracts/BindingModels/EquipmentReceivingBindingModel.cs b/ComputerShopProvider/ComputerShopContracts/BindingModels/EquipmentReceivingBindingModel.cs new file mode 100644 index 0000000..20bdd22 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/BindingModels/EquipmentReceivingBindingModel.cs @@ -0,0 +1,18 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using ComputerShopDataModels.Enums; +using ComputerShopDataModels.Models; + +namespace ComputerShopContracts.BindingModels +{ + public class EquipmentReceivingBindingModel : IEquipmentReceivingModel + { + public int Id { get; set; } + public EquipmentReceivingStatus Status { get; set; } = EquipmentReceivingStatus.Неизвестен; + + public DateTime? DateImplement { get; set; } + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/BindingModels/OrderBindingModel.cs b/ComputerShopProvider/ComputerShopContracts/BindingModels/OrderBindingModel.cs new file mode 100644 index 0000000..cb46307 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/BindingModels/OrderBindingModel.cs @@ -0,0 +1,23 @@ +using ComputerShopDataModels.Enums; +using ComputerShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.BindingModels +{ + public class OrderBindingModel : IOrderModel + { + public int Id { get; set; } + public double Sum { get; set; } + + public OrderStatus Status { get; set; } = OrderStatus.Неизвестен; + + public DateTime DateCreate { get; set; } + + public DateTime? DateImplement { get; set; } = DateTime.Now; + + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/BindingModels/SupplyBindingModel.cs b/ComputerShopProvider/ComputerShopContracts/BindingModels/SupplyBindingModel.cs new file mode 100644 index 0000000..df56fde --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/BindingModels/SupplyBindingModel.cs @@ -0,0 +1,24 @@ +using ComputerShopDataModels.Enums; +using ComputerShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.BindingModels +{ + public class SupplyBindingModel : ISupplyModel + { + public int Id { get; set; } + public SupplyStatus Status { get; set; } = SupplyStatus.Неизвестен; + + public DateTime DateCreate { get; set; } = DateTime.Now; + + public DateTime? DateImplement { get; set; } + + public int OrderId { get; set; } + + public int ReceivingId { get; set; } + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/IEquipmentReceivingLogic.cs b/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/IEquipmentReceivingLogic.cs new file mode 100644 index 0000000..2852e8d --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/IEquipmentReceivingLogic.cs @@ -0,0 +1,20 @@ +using ComputerShopContracts.BindingModels; +using ComputerShopContracts.SearchModels; +using ComputerShopContracts.ViewModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.BusinessLogicContracts +{ + public interface IEquipmentReceivingLogic + { + List? ReadList(EquipmentReceivingSearchModel? model); + bool CreateOrder(EquipmentReceivingBindingModel model); + bool TakeOrderInWork(EquipmentReceivingBindingModel model); + bool FinishOrder(EquipmentReceivingBindingModel model); + bool DeliveryOrder(EquipmentReceivingBindingModel model); + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/IOrderLogic.cs b/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/IOrderLogic.cs new file mode 100644 index 0000000..82706b8 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/IOrderLogic.cs @@ -0,0 +1,23 @@ +using ComputerShopContracts.BindingModels; +using ComputerShopContracts.SearchModels; +using ComputerShopContracts.ViewModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.BusinessLogicContracts +{ + public interface IOrderLogic + { + List? ReadList(OrderSearchModel? model); + OrderViewModel? ReadElement(OrderSearchModel model); + bool CreateOrder(OrderBindingModel model); + bool Update(ComponentBindingModel model); + bool Delete(ComponentBindingModel model); + bool TakeOrderInWork(OrderBindingModel model); + bool FinishOrder(OrderBindingModel model); + bool DeliveryOrder(OrderBindingModel model); + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/ISupplyLogic.cs b/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/ISupplyLogic.cs new file mode 100644 index 0000000..8beb1cf --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/BusinessLogicContracts/ISupplyLogic.cs @@ -0,0 +1,24 @@ +using ComputerShopContracts.BindingModels; +using ComputerShopContracts.SearchModels; +using ComputerShopContracts.ViewModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.BusinessLogicContracts +{ + public interface ISupplyLogic + { + List? ReadList(SupplySearchModel? model); + SupplyViewModel? ReadElement(SupplySearchModel model); + bool Create(SupplyBindingModel model); + bool Update(SupplyBindingModel model); + bool Delete(SupplyBindingModel model); + bool CreateOrder(PurchaseBindingModel model); + bool TakeOrderInWork(PurchaseBindingModel model); + bool FinishOrder(PurchaseBindingModel model); + bool DeliveryOrder(PurchaseBindingModel model); + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/SearchModels/EquipmentReceivingSearchModel.cs b/ComputerShopProvider/ComputerShopContracts/SearchModels/EquipmentReceivingSearchModel.cs new file mode 100644 index 0000000..bcefd64 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/SearchModels/EquipmentReceivingSearchModel.cs @@ -0,0 +1,15 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.SearchModels +{ + public class EquipmentReceivingSearchModel + { + public int? Id { get; set; } + public DateTime? DateFrom { get; set; } + public DateTime? DateTo { get; set; } + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/SearchModels/OrderSearchModel.cs b/ComputerShopProvider/ComputerShopContracts/SearchModels/OrderSearchModel.cs new file mode 100644 index 0000000..dbbf64d --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/SearchModels/OrderSearchModel.cs @@ -0,0 +1,15 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.SearchModels +{ + public class OrderSearchModel + { + public int? Id { get; set; } + public DateTime? DateFrom { get; set; } + public DateTime? DateTo { get; set; } + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/SearchModels/SupplySearchModel.cs b/ComputerShopProvider/ComputerShopContracts/SearchModels/SupplySearchModel.cs new file mode 100644 index 0000000..753a162 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/SearchModels/SupplySearchModel.cs @@ -0,0 +1,15 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.SearchModels +{ + public class SupplySearchModel + { + public int? Id { get; set; } + public DateTime? DateFrom { get; set; } + public DateTime? DateTo { get; set; } + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/StorageContracts/IEquipmentReceivingStorage.cs b/ComputerShopProvider/ComputerShopContracts/StorageContracts/IEquipmentReceivingStorage.cs new file mode 100644 index 0000000..4fdf6f9 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/StorageContracts/IEquipmentReceivingStorage.cs @@ -0,0 +1,21 @@ +using ComputerShopContracts.BindingModels; +using ComputerShopContracts.SearchModels; +using ComputerShopContracts.ViewModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.StorageContracts +{ + public interface IEquipmentReceivingStorage + { + List GetFullList(); + List GetFilteredList(EquipmentReceivingSearchModel model); + EquipmentReceivingViewModel? GetElement(EquipmentReceivingSearchModel model); + EquipmentReceivingViewModel? Insert(EquipmentReceivingBindingModel model); + EquipmentReceivingViewModel? Update(EquipmentReceivingBindingModel model); + EquipmentReceivingViewModel? Delete(EquipmentReceivingBindingModel model); + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/StorageContracts/IOrderStorage.cs b/ComputerShopProvider/ComputerShopContracts/StorageContracts/IOrderStorage.cs new file mode 100644 index 0000000..30dc1c3 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/StorageContracts/IOrderStorage.cs @@ -0,0 +1,21 @@ +using ComputerShopContracts.BindingModels; +using ComputerShopContracts.SearchModels; +using ComputerShopContracts.ViewModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.StorageContracts +{ + public interface IOrderStorage + { + List GetFullList(); + List GetFilteredList(OrderSearchModel model); + OrderViewModel? GetElement(OrderSearchModel model); + OrderViewModel? Insert(OrderBindingModel model); + OrderViewModel? Update(OrderBindingModel model); + OrderViewModel? Delete(OrderBindingModel model); + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/StorageContracts/ISupplyStorage.cs b/ComputerShopProvider/ComputerShopContracts/StorageContracts/ISupplyStorage.cs new file mode 100644 index 0000000..4e4b242 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/StorageContracts/ISupplyStorage.cs @@ -0,0 +1,21 @@ +using ComputerShopContracts.BindingModels; +using ComputerShopContracts.SearchModels; +using ComputerShopContracts.ViewModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.StorageContracts +{ + public interface ISupplyStorage + { + List GetFullList(); + List GetFilteredList(SupplySearchModel model); + SupplyViewModel? GetElement(SupplySearchModel model); + SupplyViewModel? Insert(SupplyBindingModel model); + SupplyViewModel? Update(SupplyBindingModel model); + SupplyViewModel? Delete(SupplyBindingModel model); + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/ViewModels/EquipmentReceivingViewModel.cs b/ComputerShopProvider/ComputerShopContracts/ViewModels/EquipmentReceivingViewModel.cs new file mode 100644 index 0000000..d99f07b --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/ViewModels/EquipmentReceivingViewModel.cs @@ -0,0 +1,23 @@ +using ComputerShopDataModels.Enums; +using ComputerShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.ViewModels +{ + public class EquipmentReceivingViewModel : IEquipmentReceivingModel + { + [DisplayName("Статус")] + public EquipmentReceivingStatus Status { get; set; } = EquipmentReceivingStatus.Неизвестен; + + [DisplayName("Дата выполнения")] + public DateTime? DateImplement { get; set; } + + [DisplayName("Номер")] + public int Id { get; set; } + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/ViewModels/OrderViewModel.cs b/ComputerShopProvider/ComputerShopContracts/ViewModels/OrderViewModel.cs new file mode 100644 index 0000000..ceb1ff4 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/ViewModels/OrderViewModel.cs @@ -0,0 +1,30 @@ +using ComputerShopDataModels.Enums; +using ComputerShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.ViewModels +{ + public class OrderViewModel : IOrderModel + { + [DisplayName("Сумма")] + public double Sum { get; set; } + + [DisplayName("Статус")] + public OrderStatus Status { get; set; } = OrderStatus.Неизвестен; + + [DisplayName("Дата создания")] + public DateTime DateCreate { get; set; } = DateTime.Now; + + + [DisplayName("Дата выполнения")] + public DateTime? DateImplement { get; set; } + + [DisplayName("Номер")] + public int Id { get; set; } + } +} diff --git a/ComputerShopProvider/ComputerShopContracts/ViewModels/SupplyViewModel.cs b/ComputerShopProvider/ComputerShopContracts/ViewModels/SupplyViewModel.cs new file mode 100644 index 0000000..f2ce861 --- /dev/null +++ b/ComputerShopProvider/ComputerShopContracts/ViewModels/SupplyViewModel.cs @@ -0,0 +1,43 @@ +using ComputerShopDataModels.Enums; +using ComputerShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopContracts.ViewModels +{ + public class SupplyViewModel : ISupplyModel + { + [DisplayName("Статус")] + public SupplyStatus Status { get; set; } = SupplyStatus.Неизвестен; + + [DisplayName("Дата создания")] + public DateTime DateCreate { get; set; } = DateTime.Now; + + [DisplayName("Дата выполнения")] + public DateTime? DateImplement { get; set; } + + [DisplayName("Номер заказа")] + public int OrderId { get; set; } + + [DisplayName("Номер получения")] + public int ReceivingId { get; set; } + + [DisplayName("Номер")] + public int Id { get; set; } + + + + + + + + + + + + } +} diff --git a/ComputerShopProvider/ComputerShopDataModels/Enums/EquipmentReceivingStatus.cs b/ComputerShopProvider/ComputerShopDataModels/Enums/EquipmentReceivingStatus.cs new file mode 100644 index 0000000..d0c2887 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDataModels/Enums/EquipmentReceivingStatus.cs @@ -0,0 +1,9 @@ +namespace ComputerShopDataModels.Enums +{ + public enum EquipmentReceivingStatus + { + Неизвестен = -1, + Ожидается = 0, + Получено = 1 + } +} diff --git a/ComputerShopProvider/ComputerShopDataModels/Enums/OrderStatus.cs b/ComputerShopProvider/ComputerShopDataModels/Enums/OrderStatus.cs new file mode 100644 index 0000000..ced64ca --- /dev/null +++ b/ComputerShopProvider/ComputerShopDataModels/Enums/OrderStatus.cs @@ -0,0 +1,11 @@ +namespace ComputerShopDataModels.Enums +{ + public enum OrderStatus + { + Неизвестен = -1, + Принят = 0, + Выполняется = 1, + Готов = 2, + Выдан = 3 + } +} diff --git a/ComputerShopProvider/ComputerShopDataModels/Enums/SupplyStatus.cs b/ComputerShopProvider/ComputerShopDataModels/Enums/SupplyStatus.cs new file mode 100644 index 0000000..bed7258 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDataModels/Enums/SupplyStatus.cs @@ -0,0 +1,9 @@ +namespace ComputerShopDataModels.Enums +{ + public enum SupplyStatus + { + Неизвестен = -1, + Отправляется = 0, + Отправлено = 1 + } +} diff --git a/ComputerShopProvider/ComputerShopDataModels/Models/IEquipmentReceivingModel.cs b/ComputerShopProvider/ComputerShopDataModels/Models/IEquipmentReceivingModel.cs new file mode 100644 index 0000000..2092aa2 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDataModels/Models/IEquipmentReceivingModel.cs @@ -0,0 +1,10 @@ +using ComputerShopDataModels.Enums; + +namespace ComputerShopDataModels.Models +{ + public interface IEquipmentReceivingModel : IId + { + EquipmentReceivingStatus Status { get; } + DateTime? DateImplement { get; } + } +} diff --git a/ComputerShopProvider/ComputerShopDataModels/IId.cs b/ComputerShopProvider/ComputerShopDataModels/Models/IId.cs similarity index 100% rename from ComputerShopProvider/ComputerShopDataModels/IId.cs rename to ComputerShopProvider/ComputerShopDataModels/Models/IId.cs diff --git a/ComputerShopProvider/ComputerShopDataModels/Models/IOrderModel.cs b/ComputerShopProvider/ComputerShopDataModels/Models/IOrderModel.cs new file mode 100644 index 0000000..37753b3 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDataModels/Models/IOrderModel.cs @@ -0,0 +1,12 @@ +using ComputerShopDataModels.Enums; + +namespace ComputerShopDataModels.Models +{ + public interface IOrderModel : IId + { + double Sum { get; } + OrderStatus Status { get; } + DateTime DateCreate { get; } + DateTime? DateImplement { get; } + } +} diff --git a/ComputerShopProvider/ComputerShopDataModels/Models/ISupplyModel.cs b/ComputerShopProvider/ComputerShopDataModels/Models/ISupplyModel.cs new file mode 100644 index 0000000..2cfa9e0 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDataModels/Models/ISupplyModel.cs @@ -0,0 +1,13 @@ +using ComputerShopDataModels.Enums; + +namespace ComputerShopDataModels.Models +{ + public interface ISupplyModel : IId + { + SupplyStatus Status { get; } + DateTime DateCreate { get; } + DateTime? DateImplement { get; } + int OrderId { get; } + int ReceivingId { get; } + } +} diff --git a/ComputerShopProvider/ComputerShopDatabaseImplement/ComputerShopDatabase.cs b/ComputerShopProvider/ComputerShopDatabaseImplement/ComputerShopDatabase.cs index eda5983..f416254 100644 --- a/ComputerShopProvider/ComputerShopDatabaseImplement/ComputerShopDatabase.cs +++ b/ComputerShopProvider/ComputerShopDatabaseImplement/ComputerShopDatabase.cs @@ -23,5 +23,9 @@ namespace ComputerShopDatabaseImplement public virtual DbSet Assemblies { set; get; } public virtual DbSet AssemblyComponents { set; get; } public virtual DbSet Purchases { set; get; } + public virtual DbSet Orders { set; get; } + public virtual DbSet Supplies { set; get; } + public virtual DbSet SupplyOrders { set; get; } + public virtual DbSet EquipmentReceivings { set; get; } } } diff --git a/ComputerShopProvider/ComputerShopDatabaseImplement/Implements/OrderStorage.cs b/ComputerShopProvider/ComputerShopDatabaseImplement/Implements/OrderStorage.cs new file mode 100644 index 0000000..2374d45 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDatabaseImplement/Implements/OrderStorage.cs @@ -0,0 +1,49 @@ +using ComputerShopContracts.BindingModels; +using ComputerShopContracts.SearchModels; +using ComputerShopContracts.StorageContracts; +using ComputerShopContracts.ViewModels; +using Microsoft.EntityFrameworkCore; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopDatabaseImplement.Implements +{ + internal class OrderStorage : IOrderStorage + { + public OrderViewModel? Delete(OrderBindingModel model) + { + throw new NotImplementedException(); + } + + public OrderViewModel? GetElement(OrderSearchModel model) + { + throw new NotImplementedException(); + } + + public List GetFilteredList(OrderSearchModel model) + { + throw new NotImplementedException(); + } + + public List GetFullList() + { + using var context = new ComputerShopDatabase(); + return context.Orders + .Select(x => x.GetViewModel) + .ToList(); + } + + public OrderViewModel? Insert(OrderBindingModel model) + { + throw new NotImplementedException(); + } + + public OrderViewModel? Update(OrderBindingModel model) + { + throw new NotImplementedException(); + } + } +} diff --git a/ComputerShopProvider/ComputerShopDatabaseImplement/Models/Order.cs b/ComputerShopProvider/ComputerShopDatabaseImplement/Models/Order.cs new file mode 100644 index 0000000..3ea9129 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDatabaseImplement/Models/Order.cs @@ -0,0 +1,73 @@ +using ComputerShopContracts.BindingModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using ComputerShopDataModels.Enums; +using ComputerShopContracts.ViewModels; +using ComputerShopDataModels.Models; + +namespace ComputerShopDatabaseImplement.Models +{ + internal class Order : IOrderModel + { + public int Id { get; private set; } + [Required] + public double Sum { get; private set; } + [Required] + public OrderStatus Status { get; private set; } = OrderStatus.Неизвестен; + [Required] + public DateTime DateCreate { get; private set; } = DateTime.Now; + + public DateTime? DateImplement { get; private set; } + [ForeignKey("OrderId")] + public virtual List SupplyOrders { get; set; } = + new(); + public static Order? Create(OrderBindingModel model) + { + if (model == null) + { + return null; + } + return new Order() + { + Id = model.Id, + Sum = model.Sum, + Status = model.Status, + DateCreate = model.DateCreate, + DateImplement = model.DateImplement, + }; + } + public static Order Create(OrderViewModel model) + { + return new Order + { + Id = model.Id, + Sum = model.Sum, + Status = model.Status, + DateCreate = model.DateCreate, + DateImplement = model.DateImplement, + }; + } + public void Update(OrderBindingModel model) + { + if (model == null) + { + return; + } + Status = model.Status; + DateImplement = model.DateImplement; + } + public OrderViewModel GetViewModel => new() + { + Id = Id, + Sum = Sum, + Status = Status, + DateCreate = DateCreate, + DateImplement = DateImplement, + }; + } +} diff --git a/ComputerShopProvider/ComputerShopDatabaseImplement/Models/SupplyOrder.cs b/ComputerShopProvider/ComputerShopDatabaseImplement/Models/SupplyOrder.cs new file mode 100644 index 0000000..86c8133 --- /dev/null +++ b/ComputerShopProvider/ComputerShopDatabaseImplement/Models/SupplyOrder.cs @@ -0,0 +1,22 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ComputerShopDatabaseImplement.Models +{ + internal class SupplyOrder + { + public int Id { get; set; } + [Required] + public int SupplyId { get; set; } + [Required] + public int OrderId { get; set; } + [Required] + public int Count { get; set; } + public virtual Order Order { get; set; } = new(); + public virtual Supply Supply { get; set; } = new(); + } +}