From e1c0c1942e30a41e1f2bf9c6cb0cfbc8d717652e Mon Sep 17 00:00:00 2001 From: VictoriaPresnyakova Date: Sun, 5 Feb 2023 18:01:09 +0400 Subject: [PATCH] =?UTF-8?q?=D0=9F=D1=80=D0=BE=D0=B5=D0=BA=D1=82=20=D1=81?= =?UTF-8?q?=20=D0=BC=D0=BE=D0=B4=D0=B5=D0=BB=D1=8F=D0=BC=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AbstractJewelryStoreModels.csproj | 9 +++++++++ .../Enums/OrderStatus.cs | 11 ++++++++++ AbstractJewelryStoreModels/IId.cs | 7 +++++++ .../Models/IComponentModel.cs | 14 +++++++++++++ .../Models/IOrderModel.cs | 20 +++++++++++++++++++ .../Models/IProductModel.cs | 16 +++++++++++++++ 6 files changed, 77 insertions(+) create mode 100644 AbstractJewelryStoreModels/AbstractJewelryStoreModels.csproj create mode 100644 AbstractJewelryStoreModels/Enums/OrderStatus.cs create mode 100644 AbstractJewelryStoreModels/IId.cs create mode 100644 AbstractJewelryStoreModels/Models/IComponentModel.cs create mode 100644 AbstractJewelryStoreModels/Models/IOrderModel.cs create mode 100644 AbstractJewelryStoreModels/Models/IProductModel.cs diff --git a/AbstractJewelryStoreModels/AbstractJewelryStoreModels.csproj b/AbstractJewelryStoreModels/AbstractJewelryStoreModels.csproj new file mode 100644 index 0000000..27ac386 --- /dev/null +++ b/AbstractJewelryStoreModels/AbstractJewelryStoreModels.csproj @@ -0,0 +1,9 @@ + + + + net6.0 + enable + enable + + + diff --git a/AbstractJewelryStoreModels/Enums/OrderStatus.cs b/AbstractJewelryStoreModels/Enums/OrderStatus.cs new file mode 100644 index 0000000..158ca89 --- /dev/null +++ b/AbstractJewelryStoreModels/Enums/OrderStatus.cs @@ -0,0 +1,11 @@ +namespace AbstractJewelryStoreModels.Enums +{ + public enum OrderStatus + { + Неизвестен = -1, + Принят = 0, + Выполняется = 1, + Готов = 2, + Выдан = 3 + } +} \ No newline at end of file diff --git a/AbstractJewelryStoreModels/IId.cs b/AbstractJewelryStoreModels/IId.cs new file mode 100644 index 0000000..1fe2397 --- /dev/null +++ b/AbstractJewelryStoreModels/IId.cs @@ -0,0 +1,7 @@ +namespace AbstractJewelryStoreModels +{ + public interface IId + { + int Id { get; } + } +} diff --git a/AbstractJewelryStoreModels/Models/IComponentModel.cs b/AbstractJewelryStoreModels/Models/IComponentModel.cs new file mode 100644 index 0000000..c935902 --- /dev/null +++ b/AbstractJewelryStoreModels/Models/IComponentModel.cs @@ -0,0 +1,14 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace AbstractJewelryStoreModels.Models +{ + internal class IComponentModel : IId + { + string ComponentName { get; } + double Cost { get; } + } +} diff --git a/AbstractJewelryStoreModels/Models/IOrderModel.cs b/AbstractJewelryStoreModels/Models/IOrderModel.cs new file mode 100644 index 0000000..4b792ce --- /dev/null +++ b/AbstractJewelryStoreModels/Models/IOrderModel.cs @@ -0,0 +1,20 @@ +using AbstractJewelryStoreModels.Enums; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace AbstractJewelryStoreModels.Models +{ + internal class IOrderModel : IId + { + int ProductId { get; } + int Count { get; } + double Sum { get; } + OrderStatus Status { get; } + DateTime DateCreate { get; } + DateTime? DateImplement { get; } + + } +} diff --git a/AbstractJewelryStoreModels/Models/IProductModel.cs b/AbstractJewelryStoreModels/Models/IProductModel.cs new file mode 100644 index 0000000..c131dfc --- /dev/null +++ b/AbstractJewelryStoreModels/Models/IProductModel.cs @@ -0,0 +1,16 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace AbstractJewelryStoreModels.Models +{ + internal class IProductModel : IId + { + string ProductName { get; } + double Price { get; } + Dictionary ProductComponents { get; } + + } +}