merged business logic
This commit is contained in:
parent
799fe59d75
commit
c7871c3866
@ -3,17 +3,15 @@ Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 17
|
||||
VisualStudioVersion = 17.5.33530.505
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FurnitureAssemblyDatabaseImplement", "FurnitureAssemblyDatabaseImplement\FurnitureAssemblyDatabaseImplement.csproj", "{DA551811-3214-4ACF-AFF2-ABBB03433197}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FurnitureAssemblyDatabaseImplement", "FurnitureAssemblyDatabaseImplement\FurnitureAssemblyDatabaseImplement.csproj", "{DA551811-3214-4ACF-AFF2-ABBB03433197}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FurnitureAssemblyDataModels", "FurnitureAssemblyDataModels\FurnitureAssemblyDataModels.csproj", "{2F768259-EC56-4B2A-85EB-E1949177E325}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FurnitureAssemblyDataModels", "FurnitureAssemblyDataModels\FurnitureAssemblyDataModels.csproj", "{2F768259-EC56-4B2A-85EB-E1949177E325}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FurnitureAssemblyContracts", "FurnitureAssemblyContracts\FurnitureAssemblyContracts.csproj", "{E9ADA102-08E1-4CB7-9424-43FC3AD2F4F0}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FurnitureAssemblyContracts", "FurnitureAssemblyContracts\FurnitureAssemblyContracts.csproj", "{E9ADA102-08E1-4CB7-9424-43FC3AD2F4F0}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FurnitureAssembly_WorkerBusinessLogic", "FurnitureAssembly_WorkerBusinessLogic\FurnitureAssembly_WorkerBusinessLogic.csproj", "{FEB1F9F4-0B3E-442B-8A0E-6CD2309B4535}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FurnitureAssembly", "FurnitureAssembly\FurnitureAssembly.csproj", "{C7E2829D-78C7-400B-8BBB-47FE7B2DB878}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FurnitureAssembly", "FurnitureAssembly\FurnitureAssembly.csproj", "{C7E2829D-78C7-400B-8BBB-47FE7B2DB878}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FurnitureAssembly_StorekeeperBusinessLogic", "FurnitureAssembly_StorekeeperBusinessLogic\FurnitureAssembly_StorekeeperBusinessLogic.csproj", "{17943309-2629-4D3D-B39B-14AE9F6C473F}"
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FurnitureAssemblyBusinessLogic", "FurnitureAssemblyBusinessLogic\FurnitureAssemblyBusinessLogic.csproj", "{D7934CFF-BB47-4F7A-8B6D-2FF213542B5B}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
@ -33,18 +31,14 @@ Global
|
||||
{E9ADA102-08E1-4CB7-9424-43FC3AD2F4F0}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{E9ADA102-08E1-4CB7-9424-43FC3AD2F4F0}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{E9ADA102-08E1-4CB7-9424-43FC3AD2F4F0}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{FEB1F9F4-0B3E-442B-8A0E-6CD2309B4535}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{FEB1F9F4-0B3E-442B-8A0E-6CD2309B4535}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{FEB1F9F4-0B3E-442B-8A0E-6CD2309B4535}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{FEB1F9F4-0B3E-442B-8A0E-6CD2309B4535}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{C7E2829D-78C7-400B-8BBB-47FE7B2DB878}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{C7E2829D-78C7-400B-8BBB-47FE7B2DB878}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{C7E2829D-78C7-400B-8BBB-47FE7B2DB878}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{C7E2829D-78C7-400B-8BBB-47FE7B2DB878}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{17943309-2629-4D3D-B39B-14AE9F6C473F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{17943309-2629-4D3D-B39B-14AE9F6C473F}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{17943309-2629-4D3D-B39B-14AE9F6C473F}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{17943309-2629-4D3D-B39B-14AE9F6C473F}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{D7934CFF-BB47-4F7A-8B6D-2FF213542B5B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{D7934CFF-BB47-4F7A-8B6D-2FF213542B5B}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{D7934CFF-BB47-4F7A-8B6D-2FF213542B5B}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{D7934CFF-BB47-4F7A-8B6D-2FF213542B5B}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
@ -1,8 +1,8 @@
|
||||
using FurnitureAssembly_WorkerContracts.BindingModels;
|
||||
using FurnitureAssembly_WorkerContracts.BusinessLogicContracts;
|
||||
using FurnitureAssembly_WorkerContracts.SearchModels;
|
||||
using FurnitureAssembly_WorkerContracts.StorageContracts;
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyContracts.BindingModels;
|
||||
using FurnitureAssemblyContracts.BusinessLogicContracts;
|
||||
using FurnitureAssemblyContracts.SearchModels;
|
||||
using FurnitureAssemblyContracts.StorageContracts;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@ -10,7 +10,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.BusinessLogics
|
||||
namespace FurnitureAssemblyBusinessLogic.BusinessLogics
|
||||
{
|
||||
public class FurnitureModuleLogic : IFurnitureModuleLogic
|
||||
{
|
@ -1,8 +1,8 @@
|
||||
using FurnitureAssembly_WorkerContracts.BindingModels;
|
||||
using FurnitureAssembly_WorkerContracts.BusinessLogicContracts;
|
||||
using FurnitureAssembly_WorkerContracts.SearchModels;
|
||||
using FurnitureAssembly_WorkerContracts.StorageContracts;
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyContracts.BindingModels;
|
||||
using FurnitureAssemblyContracts.BusinessLogicContracts;
|
||||
using FurnitureAssemblyContracts.SearchModels;
|
||||
using FurnitureAssemblyContracts.StorageContracts;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@ -10,7 +10,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.BusinessLogics
|
||||
namespace FurnitureAssemblyBusinessLogic.BusinessLogics
|
||||
{
|
||||
public class OrderLogic : IOrderLogic
|
||||
{
|
@ -1,17 +1,17 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels;
|
||||
using FurnitureAssembly_WorkerContracts.BindingModels;
|
||||
using FurnitureAssembly_WorkerContracts.BusinessLogicContracts;
|
||||
using FurnitureAssembly_WorkerContracts.SearchModels;
|
||||
using FurnitureAssembly_WorkerContracts.StorageContracts;
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels;
|
||||
using FurnitureAssemblyContracts.BindingModels;
|
||||
using FurnitureAssemblyContracts.BusinessLogicContracts;
|
||||
using FurnitureAssemblyContracts.SearchModels;
|
||||
using FurnitureAssemblyContracts.StorageContracts;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.BusinessLogics
|
||||
namespace FurnitureAssemblyBusinessLogic.BusinessLogics
|
||||
{
|
||||
public class ReportLogic : IReportLogic
|
||||
{
|
@ -1,8 +1,8 @@
|
||||
using FurnitureAssembly_WorkerContracts.BindingModels;
|
||||
using FurnitureAssembly_WorkerContracts.BusinessLogicContracts;
|
||||
using FurnitureAssembly_WorkerContracts.SearchModels;
|
||||
using FurnitureAssembly_WorkerContracts.StorageContracts;
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyContracts.BindingModels;
|
||||
using FurnitureAssemblyContracts.BusinessLogicContracts;
|
||||
using FurnitureAssemblyContracts.SearchModels;
|
||||
using FurnitureAssemblyContracts.StorageContracts;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@ -10,7 +10,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.BusinessLogics
|
||||
namespace FurnitureAssemblyBusinessLogic.BusinessLogics
|
||||
{
|
||||
public class RoleLogic : IRoleLogic
|
||||
{
|
@ -1,8 +1,8 @@
|
||||
using FurnitureAssembly_WorkerContracts.BindingModels;
|
||||
using FurnitureAssembly_WorkerContracts.BusinessLogicContracts;
|
||||
using FurnitureAssembly_WorkerContracts.SearchModels;
|
||||
using FurnitureAssembly_WorkerContracts.StorageContracts;
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyContracts.BindingModels;
|
||||
using FurnitureAssemblyContracts.BusinessLogicContracts;
|
||||
using FurnitureAssemblyContracts.SearchModels;
|
||||
using FurnitureAssemblyContracts.StorageContracts;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@ -10,7 +10,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.BusinessLogics
|
||||
namespace FurnitureAssemblyBusinessLogic.BusinessLogics
|
||||
{
|
||||
public class SetLogic : ISetLogic
|
||||
{
|
@ -1,8 +1,8 @@
|
||||
using FurnitureAssembly_WorkerContracts.BindingModels;
|
||||
using FurnitureAssembly_WorkerContracts.BusinessLogicContracts;
|
||||
using FurnitureAssembly_WorkerContracts.SearchModels;
|
||||
using FurnitureAssembly_WorkerContracts.StorageContracts;
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyContracts.BindingModels;
|
||||
using FurnitureAssemblyContracts.BusinessLogicContracts;
|
||||
using FurnitureAssemblyContracts.SearchModels;
|
||||
using FurnitureAssemblyContracts.StorageContracts;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@ -10,7 +10,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.BusinessLogics
|
||||
namespace FurnitureAssemblyBusinessLogic.BusinessLogics
|
||||
{
|
||||
internal class UserLogic : IUserLogic
|
||||
{
|
@ -7,7 +7,12 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="DocumentFormat.OpenXml" Version="2.20.0" />
|
||||
<PackageReference Include="MailKit" Version="4.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="7.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Logging" Version="7.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="7.0.0" />
|
||||
<PackageReference Include="PdfSharp.MigraDoc.Standard" Version="1.51.15" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
@ -1,12 +1,12 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage
|
||||
{
|
||||
public abstract class AbstractSaveToExcel
|
||||
{
|
@ -1,5 +1,5 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels;
|
||||
using MigraDoc.DocumentObjectModel;
|
||||
using MigraDoc.Rendering;
|
||||
using System;
|
||||
@ -8,7 +8,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage
|
||||
{
|
||||
public abstract class AbstractSaveToPdf
|
||||
{
|
@ -1,12 +1,12 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage
|
||||
{
|
||||
public abstract class AbstractSaveToWord
|
||||
{
|
@ -4,7 +4,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums
|
||||
{
|
||||
public enum ExcelStyleInfoType
|
||||
{
|
@ -4,7 +4,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums
|
||||
{
|
||||
public enum PdfParagraphAlignmentType
|
||||
{
|
@ -4,7 +4,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums
|
||||
{
|
||||
public enum WordJustificationType
|
||||
{
|
@ -1,11 +1,11 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class ExcelCellParameters
|
||||
{
|
@ -1,11 +1,11 @@
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class ExcelInfo
|
||||
{
|
@ -4,7 +4,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class ExcelMergeParameters
|
||||
{
|
@ -1,11 +1,11 @@
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class PdfInfo
|
||||
{
|
@ -1,11 +1,11 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class PdfParagraph
|
||||
{
|
@ -1,11 +1,11 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class PdfRowParameters
|
||||
{
|
@ -1,11 +1,11 @@
|
||||
using FurnitureAssembly_WorkerContracts.ViewModels;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class WordInfo
|
||||
{
|
@ -4,7 +4,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class WordParagraph
|
||||
{
|
@ -1,11 +1,11 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels
|
||||
{
|
||||
public class WordTextProperties
|
||||
{
|
@ -3,15 +3,15 @@ using DocumentFormat.OpenXml.Office2013.Excel;
|
||||
using DocumentFormat.OpenXml.Packaging;
|
||||
using DocumentFormat.OpenXml.Spreadsheet;
|
||||
using DocumentFormat.OpenXml;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.Implements
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.Implements
|
||||
{
|
||||
public class SaveToExcel : AbstractSaveToExcel
|
||||
{
|
@ -1,5 +1,5 @@
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels;
|
||||
using MigraDoc.DocumentObjectModel;
|
||||
using MigraDoc.Rendering;
|
||||
using MigraDoc.DocumentObjectModel.Tables;
|
||||
@ -9,7 +9,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.Implements
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.Implements
|
||||
{
|
||||
public class SaveToPdf : AbstractSaveToPdf
|
||||
{
|
@ -1,15 +1,15 @@
|
||||
using DocumentFormat.OpenXml.Packaging;
|
||||
using DocumentFormat.OpenXml.Wordprocessing;
|
||||
using DocumentFormat.OpenXml;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssembly_WorkerBusinessLogic.OfficePackage.HelperModels;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperEnums;
|
||||
using FurnitureAssemblyBusinessLogic.OfficePackage.HelperModels;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_WorkerBusinessLogic.OfficePackage.Implements
|
||||
namespace FurnitureAssemblyBusinessLogic.OfficePackage.Implements
|
||||
{
|
||||
public class SaveToWord : AbstractSaveToWord
|
||||
{
|
@ -1,109 +0,0 @@
|
||||
using FurnitureAssemblyContracts.BindingModels;
|
||||
using FurnitureAssemblyContracts.BusinessLogicContracts;
|
||||
using FurnitureAssemblyContracts.SearchModels;
|
||||
using FurnitureAssemblyContracts.StorageContracts;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using Microsoft.Extensions.Logging;
|
||||
|
||||
namespace FurnitureAssembly_Storekeeper_BusinessLogic.BusinessLogics
|
||||
{
|
||||
public class RoleLogic : IRoleLogic
|
||||
{
|
||||
private readonly ILogger _logger;
|
||||
private readonly IRoleStorage _RoleStorage;
|
||||
public RoleLogic(ILogger<RoleLogic> logger, IRoleStorage
|
||||
RoleStorage)
|
||||
{
|
||||
_logger = logger;
|
||||
_RoleStorage = RoleStorage;
|
||||
}
|
||||
public List<RoleViewModel>? ReadList(RoleSearchModel? model)
|
||||
{
|
||||
_logger.LogInformation("ReadList. RoleName:{Name}.Id:{Id}", model?.Name, model?.Id);
|
||||
var list = model == null ? _RoleStorage.GetFullList() :
|
||||
_RoleStorage.GetFilteredList(model);
|
||||
if (list == null)
|
||||
{
|
||||
_logger.LogWarning("ReadList return null list");
|
||||
return null;
|
||||
}
|
||||
_logger.LogInformation("ReadList. Count:{Count}", list.Count);
|
||||
return list;
|
||||
}
|
||||
public RoleViewModel? ReadElement(RoleSearchModel model)
|
||||
{
|
||||
if (model == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(model));
|
||||
}
|
||||
_logger.LogInformation("ReadElement. RoleName:{Name}.Id:{Id}", model.Name, model.Id);
|
||||
|
||||
var element = _RoleStorage.GetElement(model);
|
||||
|
||||
if (element == null)
|
||||
{
|
||||
_logger.LogWarning("ReadElement element not found");
|
||||
return null;
|
||||
}
|
||||
_logger.LogInformation("ReadElement find. Id:{Id}", element.Id);
|
||||
return element;
|
||||
}
|
||||
public bool Create(RoleBindingModel model)
|
||||
{
|
||||
CheckModel(model);
|
||||
if (_RoleStorage.Insert(model) == null)
|
||||
{
|
||||
_logger.LogWarning("Insert operation failed");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
public bool Update(RoleBindingModel model)
|
||||
{
|
||||
CheckModel(model);
|
||||
if (_RoleStorage.Update(model) == null)
|
||||
{
|
||||
_logger.LogWarning("Update operation failed");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
public bool Delete(RoleBindingModel model)
|
||||
{
|
||||
CheckModel(model, false);
|
||||
_logger.LogInformation("Delete. Id:{Id}", model.Id);
|
||||
if (_RoleStorage.Delete(model) == null)
|
||||
{
|
||||
_logger.LogWarning("Delete operation failed");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
private void CheckModel(RoleBindingModel model, bool withParams =
|
||||
true)
|
||||
{
|
||||
if (model == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(model));
|
||||
}
|
||||
if (!withParams)
|
||||
{
|
||||
return;
|
||||
}
|
||||
if (string.IsNullOrEmpty(model.Name))
|
||||
{
|
||||
throw new ArgumentNullException("Нет названия роли", nameof(model.Name));
|
||||
}
|
||||
|
||||
_logger.LogInformation("Role. Name:{Name}. Id: {Id}", model.Name, model.Id);
|
||||
var element = _RoleStorage.GetElement(new RoleSearchModel
|
||||
{
|
||||
Name = model.Name
|
||||
});
|
||||
if (element != null && element.Id != model.Id)
|
||||
{
|
||||
throw new InvalidOperationException("Роль с таким названием уже есть");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,120 +0,0 @@
|
||||
using FurnitureAssemblyContracts.BindingModels;
|
||||
using FurnitureAssemblyContracts.BusinessLogicContracts;
|
||||
using FurnitureAssemblyContracts.SearchModels;
|
||||
using FurnitureAssemblyContracts.StorageContracts;
|
||||
using FurnitureAssemblyContracts.ViewModels;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FurnitureAssembly_Storekeeper_BusinessLogic.BusinessLogics
|
||||
{
|
||||
public class UserLogic : IUserLogic
|
||||
{
|
||||
private readonly ILogger _logger;
|
||||
private readonly IUserStorage _UserStorage;
|
||||
|
||||
public UserLogic(ILogger<UserLogic> logger, IUserStorage UserStorage)
|
||||
{
|
||||
_logger = logger;
|
||||
_UserStorage = UserStorage;
|
||||
}
|
||||
|
||||
public bool Create(UserBindingModel model)
|
||||
{
|
||||
CheckModel(model);
|
||||
if (_UserStorage.Insert(model) == null)
|
||||
{
|
||||
_logger.LogWarning("Insert operation failed");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public bool Delete(UserBindingModel model)
|
||||
{
|
||||
CheckModel(model, false);
|
||||
_logger.LogInformation("Delete. Id:{Id}", model.Id);
|
||||
if (_UserStorage.Delete(model) == null)
|
||||
{
|
||||
_logger.LogWarning("Delete operation failed");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public UserViewModel? ReadElement(UserSearchModel model)
|
||||
{
|
||||
if (model == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(model));
|
||||
}
|
||||
_logger.LogInformation("ReadElement. Login: {Email} Id:{ Id}", model.Login, model.Id);
|
||||
var element = _UserStorage.GetElement(model);
|
||||
if (element == null)
|
||||
{
|
||||
_logger.LogWarning("ReadElement element not found");
|
||||
return null;
|
||||
}
|
||||
_logger.LogInformation("ReadElement find. Id:{Id}", element.Id);
|
||||
return element;
|
||||
}
|
||||
|
||||
public List<UserViewModel>? ReadList(UserSearchModel? model)
|
||||
{
|
||||
_logger.LogInformation("ReadList. Login: {Email}. Id:{ Id}", model?.Login, model?.Id);
|
||||
var list = model == null ? _UserStorage.GetFullList() : _UserStorage.GetFilteredList(model);
|
||||
if (list == null)
|
||||
{
|
||||
_logger.LogWarning("ReadList return null list");
|
||||
return null;
|
||||
}
|
||||
_logger.LogInformation("ReadList. Count:{Count}", list.Count);
|
||||
return list;
|
||||
}
|
||||
|
||||
public bool Update(UserBindingModel model)
|
||||
{
|
||||
CheckModel(model);
|
||||
if (_UserStorage.Update(model) == null)
|
||||
{
|
||||
_logger.LogWarning("Update operation failed");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
private void CheckModel(UserBindingModel model, bool withParams = true)
|
||||
{
|
||||
if (model == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(model));
|
||||
}
|
||||
if (!withParams)
|
||||
{
|
||||
return;
|
||||
}
|
||||
if (string.IsNullOrEmpty(model.Name))
|
||||
{
|
||||
throw new ArgumentNullException("Нет ФИО пользователя", nameof(model.Name));
|
||||
}
|
||||
if (string.IsNullOrEmpty(model.Login))
|
||||
{
|
||||
throw new ArgumentNullException("Нет логина пользователя", nameof(model.Login));
|
||||
}
|
||||
if (string.IsNullOrEmpty(model.Password))
|
||||
{
|
||||
throw new ArgumentNullException("Нет пароля пользователя", nameof(model.Password));
|
||||
}
|
||||
_logger.LogInformation("Component. Name:{Name}. Login:{ Login}. Id: { Id}", model.Name, model.Login, model.Id);
|
||||
var element = _UserStorage.GetElement(new UserSearchModel { Login = model.Login });
|
||||
if (element != null && element.Id != model.Id)
|
||||
{
|
||||
throw new InvalidOperationException("Пользователь с таким логином уже есть");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,13 +0,0 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\FurnitureAssemblyContracts\FurnitureAssemblyContracts.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
Loading…
Reference in New Issue
Block a user