Создание слоя моделей

This commit is contained in:
Табеев Александр 2024-04-21 13:42:46 +04:00
parent cdc450dd15
commit 1bdb28d01c
10 changed files with 163 additions and 0 deletions

View File

@ -5,6 +5,8 @@ VisualStudioVersion = 17.9.34723.18
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AccountingWarehouseProductsView", "AccountingWarehouseProductsView\AccountingWarehouseProductsView.csproj", "{07DF58F2-3983-4A6D-91B6-E695C65E175A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AccountingWarehouseProductsDataModels", "AccountingWarehouseProductsDataModels\AccountingWarehouseProductsDataModels.csproj", "{765B9DAD-2EB2-4C28-B6DD-4670807CB7DC}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@ -15,6 +17,10 @@ Global
{07DF58F2-3983-4A6D-91B6-E695C65E175A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{07DF58F2-3983-4A6D-91B6-E695C65E175A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{07DF58F2-3983-4A6D-91B6-E695C65E175A}.Release|Any CPU.Build.0 = Release|Any CPU
{765B9DAD-2EB2-4C28-B6DD-4670807CB7DC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{765B9DAD-2EB2-4C28-B6DD-4670807CB7DC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{765B9DAD-2EB2-4C28-B6DD-4670807CB7DC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{765B9DAD-2EB2-4C28-B6DD-4670807CB7DC}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

View File

@ -0,0 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
</Project>

View File

@ -0,0 +1,25 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AccountingWarehouseProductsDataModels.Enums
{
public enum MovementProductStatus
{
Неизвестен = -1,
Заказан = 0,
Пришёл = 1,
Принят = 2,
Расстановлен = 3,
Проверен = 4,
Доставлен = 5
}
}

View File

@ -0,0 +1,13 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AccountingWarehouseProductsDataModels
{
public interface IId
{
int Id { get; }
}
}

View File

@ -0,0 +1,17 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AccountingWarehouseProductsDataModels.Models
{
public interface IOrderModel : IId
{
DateTime? DateofOrder { get; }
string Status { get; }
Dictionary<int, (IProductModel, int)> OrderProducts { get; }
}
}

View File

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AccountingWarehouseProductsDataModels.Models
{
public interface IProductModel : IId
{
string Name { get; }
double Cost { get; }
DateTime? ExpirationDate { get; }
string Category { get; }
}
}

View File

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AccountingWarehouseProductsDataModels.Models
{
public interface IShipmentModel : IId
{
DateTime ShipmentDate { get; }
int Count { get; }
string Recipient { get; }
int OrderId { get; }
}
}

View File

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AccountingWarehouseProductsDataModels.Models
{
public interface IStandModel : IId
{
DateTime? DeliveryDate { get; }
int Count { get; }
int ProductId { get; }
int SupplierId { get; }
}
}

View File

@ -0,0 +1,17 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AccountingWarehouseProductsDataModels.Models
{
public interface ISupplierModel : IId
{
string Name { get; }
string ContactPerson { get; }
string Phone { get; }
}
}

View File

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AccountingWarehouseProductsDataModels.Models
{
public interface IWarehouseModel : IId
{
string Name { get; }
string Address { get; }
int Capacity { get; }
Dictionary<int, (IProductModel, int)> WarehouseProducts { get; }
}
}