Заготовки реализаций
This commit is contained in:
parent
11dbf92e28
commit
96d38784b2
@ -0,0 +1,13 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\TheButcherShopContracts\TheButcherShopContracts.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using TheButcherShopContracts.BusinessLogicContracts;
|
||||
using TheButcherShopContracts.DataModels;
|
||||
using TheButcherShopContracts.Enums;
|
||||
|
||||
namespace ButcherShopBusinessLogic.Implementations;
|
||||
|
||||
internal class PostBusinessLogicContract : IPostBusinessLogicContract
|
||||
{
|
||||
public List<PostDataModel> GetAllPosts(bool onlyActive = true)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
|
||||
public List<PostDataModel> GetAllDataOfPost(string postId)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
|
||||
public PostDataModel GetPostByData(string data)
|
||||
{
|
||||
return new("", "", PostType.None, 0, true, DateTime.UtcNow);
|
||||
}
|
||||
|
||||
public void InsertPost(PostDataModel postDataModel)
|
||||
{
|
||||
}
|
||||
|
||||
public void UpdatePost(PostDataModel postDataModel)
|
||||
{
|
||||
}
|
||||
|
||||
public void DeletePost(string id)
|
||||
{
|
||||
}
|
||||
|
||||
public void RestorePost(string id)
|
||||
{
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,41 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using TheButcherShopContracts.BusinessLogicContracts;
|
||||
using TheButcherShopContracts.DataModels;
|
||||
using TheButcherShopContracts.Enums;
|
||||
|
||||
namespace ButcherShopBusinessLogic.Implementations;
|
||||
|
||||
internal class ProductBusinessLogicContract : IProductBusinessLogicContract
|
||||
{
|
||||
public List<ProductDataModel> GetAllProducts(bool onlyActive)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
|
||||
public List<ProductHistoryDataModel> GetProductHistoryByProduct(string productId)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
|
||||
public ProductDataModel GetProductByData(string data)
|
||||
{
|
||||
return new("", "", ProductType.None, 0, true);
|
||||
}
|
||||
|
||||
public void InsertProduct(ProductDataModel productDataModel)
|
||||
{
|
||||
}
|
||||
|
||||
public void UpdateProduct(ProductDataModel productDataModel)
|
||||
{
|
||||
}
|
||||
|
||||
public void DeleteProduct(string id)
|
||||
{
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,26 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using TheButcherShopContracts.BusinessLogicContracts;
|
||||
using TheButcherShopContracts.DataModels;
|
||||
|
||||
namespace ButcherShopBusinessLogic.Implementations;
|
||||
|
||||
internal class SalaryBusinessLogicContract : ISalaryBusinessLogicContract
|
||||
{
|
||||
public List<SalaryDataModel> GetAllSalariesByPeriod(DateTime fromDate, DateTime toDate)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
|
||||
public List<SalaryDataModel> GetAllSalariesByPeriodByWorker(DateTime fromDate, DateTime toDate, string workerId)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
|
||||
public void CalculateSalaryByMounth(DateTime date)
|
||||
{
|
||||
}
|
||||
}
|
@ -0,0 +1,43 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using TheButcherShopContracts.BusinessLogicContracts;
|
||||
using TheButcherShopContracts.DataModels;
|
||||
|
||||
namespace ButcherShopBusinessLogic.Implementations;
|
||||
|
||||
internal class SaleBusinessLogicContract : ISaleBusinessLogicContract
|
||||
{
|
||||
public List<SaleDataModel> GetAllSalesByPeriod(DateTime fromDate, DateTime toDate)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
public List<SaleDataModel> GetAllSalesByWorkerByPeriod(string workerId,
|
||||
DateTime fromDate, DateTime toDate)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
public List<SaleDataModel> GetAllSalesByBuyerByPeriod(string? buyerId,
|
||||
DateTime fromDate, DateTime toDate)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
public List<SaleDataModel> GetAllSalesByProductByPeriod(string productId,
|
||||
DateTime fromDate, DateTime toDate)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
public SaleDataModel GetSaleByData(string data)
|
||||
{
|
||||
return new("", "", 0, false, []);
|
||||
}
|
||||
public void InsertSale(SaleDataModel saleDataModel)
|
||||
{
|
||||
}
|
||||
|
||||
public void CancelSale(string id)
|
||||
{
|
||||
}
|
||||
}
|
@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using TheButcherShopContracts.BusinessLogicContracts;
|
||||
using TheButcherShopContracts.DataModels;
|
||||
|
||||
namespace ButcherShopBusinessLogic.Implementations;
|
||||
|
||||
internal class WorkerBusinessLogicContract : IWorkerBusinessLogicContract
|
||||
{
|
||||
public List<WorkerDataModel> GetAllWorkers(bool onlyActive = true)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
public List<WorkerDataModel> GetAllWorkersByPost(string postId, bool
|
||||
onlyActive = true)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
public List<WorkerDataModel> GetAllWorkersByBirthDate(DateTime fromDate,
|
||||
DateTime toDate, bool onlyActive = true)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
public List<WorkerDataModel> GetAllWorkersByEmploymentDate(DateTime
|
||||
fromDate, DateTime toDate, bool onlyActive = true)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
public WorkerDataModel GetWorkerByData(string data)
|
||||
{
|
||||
return new("", "", "", "", DateTime.Now, DateTime.Now, true);
|
||||
}
|
||||
public void InsertWorker(WorkerDataModel workerDataModel)
|
||||
{
|
||||
}
|
||||
public void UpdateWorker(WorkerDataModel workerDataModel)
|
||||
{
|
||||
}
|
||||
public void DeleteWorker(string id)
|
||||
{
|
||||
}
|
||||
}
|
@ -5,7 +5,9 @@ VisualStudioVersion = 17.11.35222.181
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TheButcherShopContracts", "TheButcherShopContracts\TheButcherShopContracts.csproj", "{7F6E84F5-9CC5-4B63-BFCB-D87ACC271662}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ButcherShopTests", "ButcherShopTests\ButcherShopTests.csproj", "{CE3DE04B-7F25-450D-8AEC-E28DF2B23818}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ButcherShopTests", "ButcherShopTests\ButcherShopTests.csproj", "{CE3DE04B-7F25-450D-8AEC-E28DF2B23818}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ButcherShopBusinessLogic", "ButcherShopBusinessLogic\ButcherShopBusinessLogic.csproj", "{1C9F1D3F-1B91-441A-9840-57AA20712B14}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
@ -21,6 +23,10 @@ Global
|
||||
{CE3DE04B-7F25-450D-8AEC-E28DF2B23818}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{CE3DE04B-7F25-450D-8AEC-E28DF2B23818}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{CE3DE04B-7F25-450D-8AEC-E28DF2B23818}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{1C9F1D3F-1B91-441A-9840-57AA20712B14}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{1C9F1D3F-1B91-441A-9840-57AA20712B14}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{1C9F1D3F-1B91-441A-9840-57AA20712B14}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{1C9F1D3F-1B91-441A-9840-57AA20712B14}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
Loading…
x
Reference in New Issue
Block a user