diff --git a/PARR.AIHITLoaderWorker/Dockerfile b/PARR.AIHITLoaderWorker/Dockerfile index 87ff4dd2..c110aa4e 100644 --- a/PARR.AIHITLoaderWorker/Dockerfile +++ b/PARR.AIHITLoaderWorker/Dockerfile @@ -9,10 +9,8 @@ WORKDIR /src COPY ["NuGet.config", "."] COPY ["PARR.AIHITLoaderWorker/PARR.AIHITLoaderWorker.csproj", "PARR.AIHITLoaderWorker/"] COPY ["PARR.AIHITMainLoader/PARR.AIHITMainLoader.csproj", "PARR.AIHITMainLoader/"] -COPY ["PARR.BLL/PARR.BLL.csproj", "PARR.BLL/"] -COPY ["PARR.Common/PARR.Common.csproj", "PARR.Common/"] -COPY ["PARR.Domain/PARR.Domain.csproj", "PARR.Domain/"] COPY ["PARR.Core/PARR.Core.csproj", "PARR.Core/"] +COPY ["PARR.Domain/PARR.Domain.csproj", "PARR.Domain/"] COPY ["PARR.Infrastructure/PARR.Infrastructure.csproj", "PARR.Infrastructure/"] RUN dotnet restore "./PARR.AIHITLoaderWorker/./PARR.AIHITLoaderWorker.csproj" COPY . . diff --git a/PARR.AIHITMainLoader/AihitMainLoader.cs b/PARR.AIHITMainLoader/AihitMainLoader.cs index 2721b2da..f4e23f27 100644 --- a/PARR.AIHITMainLoader/AihitMainLoader.cs +++ b/PARR.AIHITMainLoader/AihitMainLoader.cs @@ -3,9 +3,8 @@ using Microsoft.Extensions.Logging; using PARR.AIHITMainLoader.Models; using PARR.AIHITMainLoader.Services; using PARR.AIHITMainLoader.Settings; -using PARR.BLL.Services.Interfaces; -using PARR.Core.Common; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Interfaces; +using PARR.Core.Common.Interfaces.RabbitServices; using System.Text.Encodings.Web; using System.Text.Json; diff --git a/PARR.AIHITMainLoader/AihitMainLoaderInstaller.cs b/PARR.AIHITMainLoader/AihitMainLoaderInstaller.cs index 63c72e72..3b75090b 100644 --- a/PARR.AIHITMainLoader/AihitMainLoaderInstaller.cs +++ b/PARR.AIHITMainLoader/AihitMainLoaderInstaller.cs @@ -4,7 +4,6 @@ using Microsoft.Extensions.DependencyInjection; using PARR.AIHITMainLoader.Context; using PARR.AIHITMainLoader.Services; using PARR.AIHITMainLoader.Settings; -using PARR.BLL; using PARR.Core; using PARR.Infrastructure; @@ -14,7 +13,6 @@ namespace PARR.AIHITMainLoader { public static void InstallAihitMainLoaderServices(this IServiceCollection services, IConfiguration configuration) { - services.InstallBllServices(configuration); services.AddCoreServices(configuration); services.AddInfrastructureServices(configuration); diff --git a/PARR.AIHITMainLoader/PARR.AIHITMainLoader.csproj b/PARR.AIHITMainLoader/PARR.AIHITMainLoader.csproj index de20737b..5e2c743e 100644 --- a/PARR.AIHITMainLoader/PARR.AIHITMainLoader.csproj +++ b/PARR.AIHITMainLoader/PARR.AIHITMainLoader.csproj @@ -11,7 +11,6 @@ - diff --git a/PARR.AIHITMainSyncer/AihitMainSyncer.cs b/PARR.AIHITMainSyncer/AihitMainSyncer.cs index 5b2f0078..db5c0ea0 100644 --- a/PARR.AIHITMainSyncer/AihitMainSyncer.cs +++ b/PARR.AIHITMainSyncer/AihitMainSyncer.cs @@ -2,7 +2,7 @@ using Microsoft.Extensions.Logging; using PARR.AIHITMainSyncer.Services; using PARR.AIHITMainSyncer.Settings; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Interfaces.RabbitServices; namespace PARR.AIHITMainSyncer { diff --git a/PARR.AIHITMainSyncer/AihitMainSyncerInstaller.cs b/PARR.AIHITMainSyncer/AihitMainSyncerInstaller.cs index c1628cc7..4bebc554 100644 --- a/PARR.AIHITMainSyncer/AihitMainSyncerInstaller.cs +++ b/PARR.AIHITMainSyncer/AihitMainSyncerInstaller.cs @@ -2,8 +2,9 @@ using Microsoft.Extensions.DependencyInjection; using PARR.AIHITMainSyncer.Services; using PARR.AIHITMainSyncer.Settings; -using PARR.BLL; +using PARR.Core; using PARR.DAL; +using PARR.Infrastructure; namespace PARR.AIHITMainSyncer { @@ -11,8 +12,9 @@ namespace PARR.AIHITMainSyncer { public static void InstallAihitMainSyncerServices(this IServiceCollection services, IConfiguration configuration) { - services.InstallBllServices(configuration); services.InstallDalServices(configuration); + services.AddCoreServices(configuration); + services.AddInfrastructureServices(configuration); var settings = new WorkerSettings(); configuration.GetSection(nameof(WorkerSettings)).Bind(settings); diff --git a/PARR.AIHITMainSyncer/PARR.AIHITMainSyncer.csproj b/PARR.AIHITMainSyncer/PARR.AIHITMainSyncer.csproj index 21190861..e8ef522a 100644 --- a/PARR.AIHITMainSyncer/PARR.AIHITMainSyncer.csproj +++ b/PARR.AIHITMainSyncer/PARR.AIHITMainSyncer.csproj @@ -7,8 +7,9 @@ - + + diff --git a/PARR.AIHITMainSyncer/Services/SyncerService.cs b/PARR.AIHITMainSyncer/Services/SyncerService.cs index f1781d53..00c40c51 100644 --- a/PARR.AIHITMainSyncer/Services/SyncerService.cs +++ b/PARR.AIHITMainSyncer/Services/SyncerService.cs @@ -2,7 +2,7 @@ using Microsoft.Extensions.Logging; using Newtonsoft.Json.Linq; using PARR.AIHITMainSyncer.Settings; -using PARR.BLL.Services.Interfaces; +using PARR.Core.Common.Interfaces; using PARR.DAL.Models.Unit; using PARR.DAL.Services.Interfaces.Unit; using PARR.Domain.Common.Rabbit.Messages; diff --git a/PARR.AIHITRelationshipsSyncer/AihitRelationshpsSyncerInstaller.cs b/PARR.AIHITRelationshipsSyncer/AihitRelationshpsSyncerInstaller.cs index bd1f48a1..5fe41ce6 100644 --- a/PARR.AIHITRelationshipsSyncer/AihitRelationshpsSyncerInstaller.cs +++ b/PARR.AIHITRelationshipsSyncer/AihitRelationshpsSyncerInstaller.cs @@ -5,9 +5,9 @@ using PARR.AIHITRelationshipsSyncer.Context; using PARR.AIHITRelationshipsSyncer.Services.Implementations; using PARR.AIHITRelationshipsSyncer.Services.Interfaces; using PARR.AIHITRelationshipsSyncer.Settings; -using PARR.BLL; using PARR.Core; using PARR.DAL; +using PARR.Infrastructure; namespace PARR.AIHITRelationshipsSyncer { @@ -15,10 +15,10 @@ namespace PARR.AIHITRelationshipsSyncer { public static void InstallAihitRelationshpsSyncerServices(this IServiceCollection services, IConfiguration configuration) { - services.InstallBllServices(configuration); - services.AddCoreServices(configuration); services.InstallDalServices(configuration); - + services.AddCoreServices(configuration); + services.AddInfrastructureServices(configuration); + var settings = new WorkerSettings(); configuration.GetSection(nameof(WorkerSettings)).Bind(settings); services.AddSingleton(settings); diff --git a/PARR.AIHITRelationshipsSyncer/PARR.AIHITRelationshipsSyncer.csproj b/PARR.AIHITRelationshipsSyncer/PARR.AIHITRelationshipsSyncer.csproj index 5471f1d2..39fa5489 100644 --- a/PARR.AIHITRelationshipsSyncer/PARR.AIHITRelationshipsSyncer.csproj +++ b/PARR.AIHITRelationshipsSyncer/PARR.AIHITRelationshipsSyncer.csproj @@ -11,8 +11,9 @@ - + + diff --git a/PARR.AIHITRelationshipsSyncer/RelationshipsSyncer.cs b/PARR.AIHITRelationshipsSyncer/RelationshipsSyncer.cs index ad283a88..f7f27c49 100644 --- a/PARR.AIHITRelationshipsSyncer/RelationshipsSyncer.cs +++ b/PARR.AIHITRelationshipsSyncer/RelationshipsSyncer.cs @@ -2,8 +2,7 @@ using PARR.AIHITRelationshipsSyncer.Models; using PARR.AIHITRelationshipsSyncer.Services.Interfaces; using PARR.AIHITRelationshipsSyncer.Settings; -using PARR.BLL.Services.Interfaces; -using PARR.Core.Common; +using PARR.Core.Common.Interfaces; using System.Text.Json; namespace PARR.AIHITRelationshipsSyncer diff --git a/PARR.AIHITRelationshipsSyncerWorker/Dockerfile b/PARR.AIHITRelationshipsSyncerWorker/Dockerfile index 9930beb6..09638974 100644 --- a/PARR.AIHITRelationshipsSyncerWorker/Dockerfile +++ b/PARR.AIHITRelationshipsSyncerWorker/Dockerfile @@ -12,11 +12,10 @@ WORKDIR /src COPY ["NuGet.config", "."] COPY ["PARR.AIHITRelationshipsSyncerWorker/PARR.AIHITRelationshipsSyncerWorker.csproj", "PARR.AIHITRelationshipsSyncerWorker/"] COPY ["PARR.AIHITRelationshipsSyncer/PARR.AIHITRelationshipsSyncer.csproj", "PARR.AIHITRelationshipsSyncer/"] -COPY ["PARR.BLL/PARR.BLL.csproj", "PARR.BLL/"] -COPY ["PARR.Common/PARR.Common.csproj", "PARR.Common/"] +COPY ["PARR.Core/PARR.Core.csproj", "PARR.Core/"] COPY ["PARR.Domain/PARR.Domain.csproj", "PARR.Domain/"] COPY ["PARR.DAL/PARR.DAL.csproj", "PARR.DAL/"] -COPY ["PARR.Core/PARR.Core.csproj", "PARR.Core/"] +COPY ["PARR.Infrastructure/PARR.Infrastructure.csproj", "PARR.Infrastructure/"] RUN dotnet restore "./PARR.AIHITRelationshipsSyncerWorker/PARR.AIHITRelationshipsSyncerWorker.csproj" COPY . . WORKDIR "/src/PARR.AIHITRelationshipsSyncerWorker" diff --git a/PARR.AIHITSyncerWorker/Dockerfile b/PARR.AIHITSyncerWorker/Dockerfile index a9847f80..c3a83ca3 100644 --- a/PARR.AIHITSyncerWorker/Dockerfile +++ b/PARR.AIHITSyncerWorker/Dockerfile @@ -9,11 +9,10 @@ WORKDIR /src COPY ["NuGet.config", "."] COPY ["PARR.AIHITSyncerWorker/PARR.AIHITSyncerWorker.csproj", "PARR.AIHITSyncerWorker/"] COPY ["PARR.AIHITMainSyncer/PARR.AIHITMainSyncer.csproj", "PARR.AIHITMainSyncer/"] -COPY ["PARR.BLL/PARR.BLL.csproj", "PARR.BLL/"] -COPY ["PARR.Common/PARR.Common.csproj", "PARR.Common/"] +COPY ["PARR.Core/PARR.Core.csproj", "PARR.Core/"] COPY ["PARR.Domain/PARR.Domain.csproj", "PARR.Domain/"] COPY ["PARR.DAL/PARR.DAL.csproj", "PARR.DAL/"] -COPY ["PARR.Core/PARR.Core.csproj", "PARR.Core/"] +COPY ["PARR.Infrastructure/PARR.Infrastructure.csproj", "PARR.Infrastructure/"] RUN dotnet restore "./PARR.AIHITSyncerWorker/./PARR.AIHITSyncerWorker.csproj" COPY . . WORKDIR "/src/PARR.AIHITSyncerWorker" diff --git a/PARR.API.sln b/PARR.API.sln index 6c55f29e..0855d326 100644 --- a/PARR.API.sln +++ b/PARR.API.sln @@ -20,8 +20,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution EndProject Project("{E53339B2-1760-4266-BCC7-CA923CBCF16C}") = "docker-compose", "docker-compose.dcproj", "{AB278172-BFB4-4D54-9022-2D2A5B3338D7}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PARR.BLL", "PARR.BLL\PARR.BLL.csproj", "{7BAB9170-743D-4542-8881-9B161EE81BB6}" -EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PARR.EsppTemplateSyncWorker", "PARR.EsppTemplateSyncWorker\PARR.EsppTemplateSyncWorker.csproj", "{7FBD65FE-26FE-4E60-AD1F-20AAC6F88C7A}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PARR.EsppTemplateSync", "PARR.EsppTemplateSync\PARR.EsppTemplateSync.csproj", "{39FD9AAD-0792-46B2-A935-42486A993C32}" @@ -70,8 +68,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PARR.JobAutoControlWorker", EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PARR.JobAutoControl", "PARR.JobAutoControl\PARR.JobAutoControl.csproj", "{2C35CCD5-6DCD-4640-98DA-D2DC11CE3BA5}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PARR.Common", "PARR.Common\PARR.Common.csproj", "{5C89E990-6E49-4897-8344-1AC3ECFBD869}" -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PARR.AIHITMainLoader", "PARR.AIHITMainLoader\PARR.AIHITMainLoader.csproj", "{1BB7D841-4F6A-43B6-B89A-F0B09CDA40B1}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PARR.AIHITMainSyncer", "PARR.AIHITMainSyncer\PARR.AIHITMainSyncer.csproj", "{173E33B2-A10B-4FE9-802C-B22940326DEB}" @@ -120,10 +116,6 @@ Global {228C8124-69E4-4AE0-8C33-0438E54FF1BA}.Release|Any CPU.Build.0 = Release|Any CPU {AB278172-BFB4-4D54-9022-2D2A5B3338D7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {AB278172-BFB4-4D54-9022-2D2A5B3338D7}.Release|Any CPU.ActiveCfg = Release|Any CPU - {7BAB9170-743D-4542-8881-9B161EE81BB6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {7BAB9170-743D-4542-8881-9B161EE81BB6}.Debug|Any CPU.Build.0 = Debug|Any CPU - {7BAB9170-743D-4542-8881-9B161EE81BB6}.Release|Any CPU.ActiveCfg = Release|Any CPU - {7BAB9170-743D-4542-8881-9B161EE81BB6}.Release|Any CPU.Build.0 = Release|Any CPU {7FBD65FE-26FE-4E60-AD1F-20AAC6F88C7A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {7FBD65FE-26FE-4E60-AD1F-20AAC6F88C7A}.Debug|Any CPU.Build.0 = Debug|Any CPU {7FBD65FE-26FE-4E60-AD1F-20AAC6F88C7A}.Release|Any CPU.ActiveCfg = Release|Any CPU @@ -220,10 +212,6 @@ Global {2C35CCD5-6DCD-4640-98DA-D2DC11CE3BA5}.Debug|Any CPU.Build.0 = Debug|Any CPU {2C35CCD5-6DCD-4640-98DA-D2DC11CE3BA5}.Release|Any CPU.ActiveCfg = Release|Any CPU {2C35CCD5-6DCD-4640-98DA-D2DC11CE3BA5}.Release|Any CPU.Build.0 = Release|Any CPU - {5C89E990-6E49-4897-8344-1AC3ECFBD869}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {5C89E990-6E49-4897-8344-1AC3ECFBD869}.Debug|Any CPU.Build.0 = Debug|Any CPU - {5C89E990-6E49-4897-8344-1AC3ECFBD869}.Release|Any CPU.ActiveCfg = Release|Any CPU - {5C89E990-6E49-4897-8344-1AC3ECFBD869}.Release|Any CPU.Build.0 = Release|Any CPU {1BB7D841-4F6A-43B6-B89A-F0B09CDA40B1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {1BB7D841-4F6A-43B6-B89A-F0B09CDA40B1}.Debug|Any CPU.Build.0 = Debug|Any CPU {1BB7D841-4F6A-43B6-B89A-F0B09CDA40B1}.Release|Any CPU.ActiveCfg = Release|Any CPU diff --git a/PARR.API/Contracts/V1/Responses/MatchingStatusResponse.cs b/PARR.API/Contracts/V1/Responses/MatchingStatusResponse.cs index 016bc5ff..44ad3ae0 100644 --- a/PARR.API/Contracts/V1/Responses/MatchingStatusResponse.cs +++ b/PARR.API/Contracts/V1/Responses/MatchingStatusResponse.cs @@ -1,4 +1,4 @@ -using PARR.DAL.Cache.Models; +using PARR.Domain.Cache.Models; namespace PARR.API.Contracts.V1.Responses { diff --git a/PARR.API/Controllers/V1/DistributorController.cs b/PARR.API/Controllers/V1/DistributorController.cs index e6c2d35b..ecff455f 100644 --- a/PARR.API/Controllers/V1/DistributorController.cs +++ b/PARR.API/Controllers/V1/DistributorController.cs @@ -7,7 +7,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.API.Settings; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Interfaces.RabbitServices; using PARR.Domain.Common.Rabbit.Messages; using PARR.Domain.Common.Roles; using PARR.Domain.Entities.Base.History; diff --git a/PARR.API/Controllers/V1/GeneratorTemplateController.cs b/PARR.API/Controllers/V1/GeneratorTemplateController.cs index 61fdc7c1..9a832002 100644 --- a/PARR.API/Controllers/V1/GeneratorTemplateController.cs +++ b/PARR.API/Controllers/V1/GeneratorTemplateController.cs @@ -1,19 +1,4 @@ -using FluentValidation; -using Microsoft.AspNetCore.Authorization; -using Microsoft.AspNetCore.Mvc; -using PARR.API.Contracts.V1; -using PARR.API.Contracts.V1.Requests; -using PARR.API.Contracts.V1.Responses.Base; -using PARR.API.Controllers.V1.Base; -using PARR.API.Services.Interfaces; -using PARR.API.Settings; -using PARR.Core.Common.RabbitServices; -using PARR.Domain.Common.Rabbit.Messages; -using PARR.Domain.Common.Roles; -using PARR.Domain.Entities.Base.History; -using PARR.Domain.Enums; - -namespace PARR.API.Controllers.V1 +namespace PARR.API.Controllers.V1 { //[Authorize(Roles = ParrRoles.Administrator.Role)] //public class GeneratorTemplateController : BaseApiController diff --git a/PARR.API/Controllers/V1/JobController.cs b/PARR.API/Controllers/V1/JobController.cs index e26f3aa5..567c4ca7 100644 --- a/PARR.API/Controllers/V1/JobController.cs +++ b/PARR.API/Controllers/V1/JobController.cs @@ -13,7 +13,8 @@ using PARR.API.Extensions; using PARR.API.Services.Interfaces; using PARR.API.Settings; using PARR.BLL.Helpers; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Helpers; +using PARR.Core.Common.Interfaces.RabbitServices; using PARR.DAL.DomainServices.Interfaces; using PARR.DAL.DomainServices.UnitFilterService; using PARR.DAL.Extensions; diff --git a/PARR.API/Controllers/V1/JobGroupController.cs b/PARR.API/Controllers/V1/JobGroupController.cs index 051bce22..2192c8c9 100644 --- a/PARR.API/Controllers/V1/JobGroupController.cs +++ b/PARR.API/Controllers/V1/JobGroupController.cs @@ -13,7 +13,8 @@ using PARR.API.Extensions; using PARR.API.Services.Interfaces; using PARR.API.Settings; using PARR.BLL.Helpers; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Helpers; +using PARR.Core.Common.Interfaces.RabbitServices; using PARR.DAL.DomainServices.Interfaces; using PARR.DAL.Models; using PARR.DAL.Models.Job; diff --git a/PARR.API/Controllers/V1/JobGroupUpdateNextRunController.cs b/PARR.API/Controllers/V1/JobGroupUpdateNextRunController.cs index 38cc130a..9241fbc2 100644 --- a/PARR.API/Controllers/V1/JobGroupUpdateNextRunController.cs +++ b/PARR.API/Controllers/V1/JobGroupUpdateNextRunController.cs @@ -5,7 +5,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Settings; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Interfaces.RabbitServices; using PARR.DAL.Services.Interfaces.Job; using PARR.Domain.Common.Rabbit.Messages; using PARR.Domain.Common.Roles; diff --git a/PARR.API/Controllers/V1/Statistics/StatAuthController.cs b/PARR.API/Controllers/V1/Statistics/StatAuthController.cs index 7a16e14d..3c3ca48b 100644 --- a/PARR.API/Controllers/V1/Statistics/StatAuthController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatAuthController.cs @@ -5,9 +5,9 @@ using PARR.API.Contracts.V1.Requests.Queries; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; -using PARR.DAL.InfluxDbServices; -using PARR.DAL.Settings; +using PARR.Core.Common.Interfaces; using PARR.Domain.Common.Roles; +using PARR.Domain.Settings; namespace PARR.API.Controllers.V1.Statistics { diff --git a/PARR.API/Controllers/V1/Statistics/StatRabbitMqController.cs b/PARR.API/Controllers/V1/Statistics/StatRabbitMqController.cs index aeddd328..e98e88de 100644 --- a/PARR.API/Controllers/V1/Statistics/StatRabbitMqController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatRabbitMqController.cs @@ -5,7 +5,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Settings; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Interfaces.RabbitServices; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1.Statistics diff --git a/PARR.API/Controllers/V1/Statistics/StatRobotStateController.cs b/PARR.API/Controllers/V1/Statistics/StatRobotStateController.cs index 55c7e5a9..b6fc9dae 100644 --- a/PARR.API/Controllers/V1/Statistics/StatRobotStateController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatRobotStateController.cs @@ -14,11 +14,11 @@ using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.API.Settings; -using PARR.DAL.InfluxDbServices; +using PARR.Core.Common.Interfaces; using PARR.DAL.Services.Interfaces; -using PARR.DAL.Settings; using PARR.Domain.Common.Roles; using PARR.Domain.Enums; +using PARR.Domain.Settings; namespace PARR.API.Controllers.V1.Statistics { diff --git a/PARR.API/Controllers/V1/SyncTaskController.cs b/PARR.API/Controllers/V1/SyncTaskController.cs index 63a3aec1..ec66348e 100644 --- a/PARR.API/Controllers/V1/SyncTaskController.cs +++ b/PARR.API/Controllers/V1/SyncTaskController.cs @@ -5,7 +5,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.API.Settings; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Interfaces.RabbitServices; using PARR.DAL.DomainServices.Interfaces; using PARR.Domain.Common.Rabbit.Messages; using PARR.Domain.Entities.Base.History; diff --git a/PARR.API/Controllers/V1/TemplateActivatorController.cs b/PARR.API/Controllers/V1/TemplateActivatorController.cs index 44f973d2..f6a89022 100644 --- a/PARR.API/Controllers/V1/TemplateActivatorController.cs +++ b/PARR.API/Controllers/V1/TemplateActivatorController.cs @@ -7,7 +7,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.API.Settings; -using PARR.Core.Common.RabbitServices; +using PARR.Core.Common.Interfaces.RabbitServices; using PARR.DAL.Services.Interfaces.Job; using PARR.Domain.Common.Rabbit.Messages; using PARR.Domain.Common.Roles; diff --git a/PARR.API/Controllers/V1/TemplateController.cs b/PARR.API/Controllers/V1/TemplateController.cs index e28dd643..dfdb8dbd 100644 --- a/PARR.API/Controllers/V1/TemplateController.cs +++ b/PARR.API/Controllers/V1/TemplateController.cs @@ -11,6 +11,7 @@ using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; using PARR.BLL.Helpers; +using PARR.Core.Common.Helpers; using PARR.DAL.Contracts; using PARR.DAL.DomainServices.Shortcodes; using PARR.DAL.Models; diff --git a/PARR.API/Controllers/V1/TestController.cs b/PARR.API/Controllers/V1/TestController.cs index 04515187..9aa20997 100644 --- a/PARR.API/Controllers/V1/TestController.cs +++ b/PARR.API/Controllers/V1/TestController.cs @@ -5,7 +5,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.API.Settings; -using PARR.DAL.Cache.Services.Base; +using PARR.Core.Common.Interfaces; using PARR.DAL.NextRunServices; using PARR.DAL.Services.Interfaces; diff --git a/PARR.API/Controllers/V1/UnitController.cs b/PARR.API/Controllers/V1/UnitController.cs index 07d9f3ed..885b69a3 100644 --- a/PARR.API/Controllers/V1/UnitController.cs +++ b/PARR.API/Controllers/V1/UnitController.cs @@ -9,6 +9,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.BLL.Helpers; +using PARR.Core.Common.Helpers; using PARR.DAL.Models.Unit; using PARR.DAL.Services.Interfaces.Unit; using PARR.Domain.Common.Pagination; diff --git a/PARR.API/Controllers/V1/UnitFieldValueController.cs b/PARR.API/Controllers/V1/UnitFieldValueController.cs index 849be477..dc3583c6 100644 --- a/PARR.API/Controllers/V1/UnitFieldValueController.cs +++ b/PARR.API/Controllers/V1/UnitFieldValueController.cs @@ -9,6 +9,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.BLL.Helpers; +using PARR.Core.Common.Helpers; using PARR.DAL.Models.Unit; using PARR.DAL.Services.Interfaces.Unit; using PARR.Domain.Common.Pagination; diff --git a/PARR.API/Dockerfile b/PARR.API/Dockerfile index 1fcb2297..a1ad1cb9 100644 --- a/PARR.API/Dockerfile +++ b/PARR.API/Dockerfile @@ -15,10 +15,8 @@ FROM 10.99.253.167:8090/dotnet/sdk:7.0 AS build WORKDIR /src COPY ["NuGet.config", "."] COPY ["PARR.API/PARR.API.csproj", "PARR.API/"] -COPY ["PARR.BLL/PARR.BLL.csproj", "PARR.BLL/"] -COPY ["PARR.Common/PARR.Common.csproj", "PARR.Common/"] -COPY ["PARR.Domain/PARR.Domain.csproj", "PARR.Domain/"] COPY ["PARR.Core/PARR.Core.csproj", "PARR.Core/"] +COPY ["PARR.Domain/PARR.Domain.csproj", "PARR.Domain/"] COPY ["PARR.DAL/PARR.DAL.csproj", "PARR.DAL/"] COPY ["PARR.Infrastructure/PARR.Infrastructure.csproj", "PARR.Infrastructure/"] RUN dotnet restore "PARR.API/PARR.API.csproj" diff --git a/PARR.API/PARR.API.csproj b/PARR.API/PARR.API.csproj index 69357422..5cdea6be 100644 --- a/PARR.API/PARR.API.csproj +++ b/PARR.API/PARR.API.csproj @@ -35,7 +35,6 @@ - diff --git a/PARR.API/Program.cs b/PARR.API/Program.cs index 25531d08..3c7e520e 100644 --- a/PARR.API/Program.cs +++ b/PARR.API/Program.cs @@ -3,7 +3,6 @@ using FluentValidation; using Microsoft.AspNetCore.HttpOverrides; using PARR.API.Authentication; using PARR.API.Installers; -using PARR.BLL; using PARR.Core; using PARR.DAL; using PARR.Infrastructure; @@ -28,7 +27,6 @@ builder.Services.InstallDalServices(builder.Configuration); builder.Services.AddCoreServices(builder.Configuration); builder.Services.AddInfrastructureServices(builder.Configuration); //---- --- ---- -builder.Services.InstallBllServices(builder.Configuration); builder.Services.InstallApiServices(builder.Configuration); builder.Services.InstallSettings(builder.Configuration); builder.Services.AddAutoMapper(AppDomain.CurrentDomain.GetAssemblies()); diff --git a/PARR.API/Services/Implementations/AuthService.cs b/PARR.API/Services/Implementations/AuthService.cs index 0dd412f0..e9fd1ebf 100644 --- a/PARR.API/Services/Implementations/AuthService.cs +++ b/PARR.API/Services/Implementations/AuthService.cs @@ -3,12 +3,11 @@ using PARR.API.Authentication.Models; using PARR.API.Domain.InfluxDbModels; using PARR.API.Services.Interfaces; using PARR.API.Settings; -using PARR.DAL.Cache.Services.Base; -using PARR.DAL.InfluxDbServices; +using PARR.Core.Common.Interfaces; using PARR.DAL.Services.Interfaces; using PARR.DAL.Services.Interfaces.Unit; -using PARR.DAL.Settings; using PARR.Domain.Common.Roles; +using PARR.Domain.Settings; namespace PARR.API.Services.Implementations { diff --git a/PARR.API/Services/Implementations/WorkLoadService.cs b/PARR.API/Services/Implementations/WorkLoadService.cs index 9f04ffd0..cad7157b 100644 --- a/PARR.API/Services/Implementations/WorkLoadService.cs +++ b/PARR.API/Services/Implementations/WorkLoadService.cs @@ -1,83 +1,80 @@ -using PARR.API.Contracts.V1.Requests.Queries; -using PARR.API.Services.Interfaces; -using PARR.BLL.Services.Interfaces; -using PARR.DAL.Models; +using PARR.API.Services.Interfaces; namespace PARR.API.Services.Implementations { internal class WorkLoadService : IWorkLoadService { - private readonly ICalendarService calendarService; + //private readonly ICalendarService calendarService; - public WorkLoadService(ICalendarService calendarService) - { - this.calendarService = calendarService; - } + //public WorkLoadService(ICalendarService calendarService) + //{ + // this.calendarService = calendarService; + //} - private DateTime GetStartDate(int timeZoneOffsetHours) - { - //(так уже не делаем) начинаем не с сегодняшнего дня, а с завтра, так как на сегодня уже некоторые работы были проведены и их дата изменилась - //return DateTimeOffset.UtcNow.AddHours(timeZoneOffsetHours).Date.AddDays(1); + //private DateTime GetStartDate(int timeZoneOffsetHours) + //{ + // //(так уже не делаем) начинаем не с сегодняшнего дня, а с завтра, так как на сегодня уже некоторые работы были проведены и их дата изменилась + // //return DateTimeOffset.UtcNow.AddHours(timeZoneOffsetHours).Date.AddDays(1); - var dateWithTimeZoneOffset = calendarService.GetDateWithTimeZoneOffset(DateTimeOffset.UtcNow, timeZoneOffsetHours); - //var dateWithAddDays = dateWithTimeZoneOffset.DateTime.AddDays(1); - var dateWithAddDays = dateWithTimeZoneOffset.DateTime.AddDays(0); + // var dateWithTimeZoneOffset = calendarService.GetDateWithTimeZoneOffset(DateTimeOffset.UtcNow, timeZoneOffsetHours); + // //var dateWithAddDays = dateWithTimeZoneOffset.DateTime.AddDays(1); + // var dateWithAddDays = dateWithTimeZoneOffset.DateTime.AddDays(0); - //var bbb = dateWithTimeZoneOffset.DateTime.AddDays(1); + // //var bbb = dateWithTimeZoneOffset.DateTime.AddDays(1); - //return calendarService.GetDateWithTimeZoneOffset(DateTimeOffset.UtcNow, timeZoneOffsetHours).UtcDateTime.AddDays(1); - return dateWithAddDays; - } + // //return calendarService.GetDateWithTimeZoneOffset(DateTimeOffset.UtcNow, timeZoneOffsetHours).UtcDateTime.AddDays(1); + // return dateWithAddDays; + //} - private DateTime GetEndDate(bool? isMonth, int timeZoneOffsetHours) - { - var startDate = GetStartDate(timeZoneOffsetHours); + //private DateTime GetEndDate(bool? isMonth, int timeZoneOffsetHours) + //{ + // var startDate = GetStartDate(timeZoneOffsetHours); - return isMonth == true ? startDate.AddDays(30) : startDate.AddDays(6); - } + // return isMonth == true ? startDate.AddDays(30) : startDate.AddDays(6); + //} - public List GetDatesForPeriod(WorkloadBaseQuery requestQuery) - { - var startDate = GetStartDate(requestQuery.TimeZoneOffsetHours); - var endDate = GetEndDate(requestQuery.IsMonth, requestQuery.TimeZoneOffsetHours); + //public List GetDatesForPeriod(WorkloadBaseQuery requestQuery) + //{ + // var startDate = GetStartDate(requestQuery.TimeZoneOffsetHours); + // var endDate = GetEndDate(requestQuery.IsMonth, requestQuery.TimeZoneOffsetHours); - //var daysList = new List(); + // //var daysList = new List(); - //daysList.Add(new DateTimeOffset(startDate, new TimeSpan(0))); + // //daysList.Add(new DateTimeOffset(startDate, new TimeSpan(0))); - //while (daysList.Last() < endDate) - // daysList.Add(daysList.Last().AddDays(1)); + // //while (daysList.Last() < endDate) + // // daysList.Add(daysList.Last().AddDays(1)); - //return daysList.OrderBy(t => t).ToList(); + // //return daysList.OrderBy(t => t).ToList(); - //var aaa = DateOnly.FromDateTime(startDate); + // //var aaa = DateOnly.FromDateTime(startDate); - return calendarService.GetDatesForPeriod(DateOnly.FromDateTime(startDate), DateOnly.FromDateTime(endDate)); - } + // return calendarService.GetDatesForPeriod(DateOnly.FromDateTime(startDate), DateOnly.FromDateTime(endDate)); + //} - public IQueryable