From eb78dfd6a810952ce04d95a394567c3b9d936795 Mon Sep 17 00:00:00 2001 From: Mikhail Trubnikov Date: Thu, 30 Apr 2026 10:35:31 +1000 Subject: [PATCH] =?UTF-8?q?feat:=20=D0=98=D0=B7=20dal=20=D0=BF=D0=B5=D1=80?= =?UTF-8?q?=D0=B5=D0=BD=D0=B5=D1=81=D0=B5=D0=BD=D1=8B=20=D0=B2=D1=81=D0=B5?= =?UTF-8?q?=20=D0=BC=D0=BE=D0=B4=D0=B5=D0=BB=D0=B8=20=D0=B2=20Domain.=20?= =?UTF-8?q?=D0=98=D0=B7=20dal=20=D0=BF=D0=B5=D1=80=D0=B5=D0=B8=D0=BC=D0=B5?= =?UTF-8?q?=D0=BD=D0=BE=D0=B2=D0=B0=D0=BD=D1=8B=20service=20=D0=B2=20repos?= =?UTF-8?q?itory,=20=D0=B2=D1=8B=D0=BD=D0=B5=D1=81=D0=B5=D0=BD=D1=8B=20?= =?UTF-8?q?=D0=B2=20Core.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AihitMainSyncerInstaller.cs | 2 +- .../Services/SyncerService.cs | 16 +- .../AihitRelationshpsSyncerInstaller.cs | 2 +- .../RelationshipsSyncService.cs | 8 +- .../Controllers/V1/AgentHistoryController.cs | 18 +- .../Controllers/V1/AgentTaskController.cs | 12 +- .../V1/DistributionPeriodController.cs | 6 +- .../V1/EsppScheduleTypeScheduleController.cs | 6 +- .../V1/JobAutoControlController.cs | 13 +- PARR.API/Controllers/V1/JobController.cs | 25 +- PARR.API/Controllers/V1/JobGroupController.cs | 30 ++- .../Controllers/V1/JobGroupTypeController.cs | 6 +- .../V1/JobGroupUpdateNextRunController.cs | 6 +- .../V1/JobUnitPreviewController.cs | 14 +- PARR.API/Controllers/V1/KiiUnitController.cs | 6 +- PARR.API/Controllers/V1/OrderController.cs | 8 +- PARR.API/Controllers/V1/ProcessController.cs | 8 +- .../V1/RegionalEkPtkGroupController.cs | 6 +- PARR.API/Controllers/V1/RobotController.cs | 6 +- .../Controllers/V1/RobotHistoryController.cs | 16 +- .../V1/RobotHistoryLevelController.cs | 6 +- .../Controllers/V1/RobotTaskController.cs | 12 +- .../V1/RobotTaskRobotStatusController.cs | 13 +- PARR.API/Controllers/V1/RoleController.cs | 6 +- .../ScheduleExcludeTypeCalendarController.cs | 6 +- .../V1/ScheduleExcludeTypeController.cs | 6 +- .../V1/ShortcodeApplyController.cs | 6 +- .../V1/Statistics/StatOrderController.cs | 10 +- .../StatResponseAreaWorkLoadController.cs | 6 +- .../Statistics/StatRobotHistoryController.cs | 12 +- .../V1/Statistics/StatRobotStateController.cs | 6 +- .../Statistics/StatRobotStatusController.cs | 14 +- .../V1/Statistics/StatRobotTaskController.cs | 18 +- .../V1/Statistics/StatStatusTypeTemplates.cs | 10 +- .../StatTemplateAutoControlController.cs | 10 +- .../V1/Statistics/StatTemplateController.cs | 6 +- .../StatTemplateDistributionController.cs | 22 +- .../V1/Statistics/StatUnitController.cs | 6 +- .../StatUnitFieldValuesController.cs | 7 +- .../StatWorkGroupWorkLoadController.cs | 6 +- .../Statistics/StatWorkWorkLoadController.cs | 15 +- .../Controllers/V1/SubprocessController.cs | 8 +- .../Controllers/V1/TaskStatusController.cs | 6 +- .../V1/TemplateActivatorController.cs | 6 +- PARR.API/Controllers/V1/TemplateController.cs | 22 +- .../V1/TemplateHistoryController.cs | 8 +- .../Controllers/V1/TemplateScheduleEspp.cs | 6 +- .../V1/TemplateStatusTypeController.cs | 6 +- .../V1/TemplateSyncStateController.cs | 10 +- PARR.API/Controllers/V1/TestController.cs | 6 +- PARR.API/Controllers/V1/TnkController.cs | 8 +- PARR.API/Controllers/V1/UnitController.cs | 9 +- .../Controllers/V1/UnitFieldController.cs | 6 +- .../V1/UnitFieldValueController.cs | 13 +- PARR.API/Controllers/V1/UserController.cs | 8 +- PARR.API/Controllers/V1/UserRoleController.cs | 12 +- PARR.API/Controllers/V1/WeekendController.cs | 8 +- .../DomainToResponseProfile.cs | 13 +- .../MappingProfiles/RequestToDomainProfile.cs | 2 +- .../HistoryInitiatorParrComponentResolver.cs | 6 +- .../Resolvers/HistoryInitiatorUserResolver.cs | 6 +- .../Resolvers/JobGroupScheduleResolver.cs | 13 +- ...obotTaskScheduleExcludeCalendarResolver.cs | 7 +- .../RobotTaskScheduleExcludeResolver.cs | 7 +- ...RobotTaskScheduleGenerationTimeResolver.cs | 9 +- .../RobotTaskScheduleNextStartResolver.cs | 9 +- .../RobotTaskScheduleRepeatRangeResolver.cs | 2 +- .../Resolvers/RobotTaskScheduleSchResolver.cs | 8 +- .../RobotTaskScheduleTimezoneResolver.cs | 7 +- .../RobotTaskTemplateCategoryResolver.cs | 2 +- .../RobotTaskTemplateClosingCodeResolver.cs | 2 +- .../RobotTaskTemplateInitiatorResolver.cs | 2 +- .../Resolvers/TemplateCategoryResolver.cs | 2 +- .../Resolvers/TemplateClosingCodeResolver.cs | 2 +- .../Resolvers/TemplateInitiatorResolver.cs | 2 +- .../Resolvers/TemplateScheduleResolver.cs | 13 +- PARR.API/Program.cs | 2 +- .../Services/Implementations/AuthService.cs | 12 +- .../Services/Interfaces/IWorkLoadService.cs | 5 +- .../Validators/DistributeRequestValidator.cs | 4 +- PARR.API/Validators/JobGroupValidator.cs | 20 +- PARR.API/Validators/JobRequestValidator.cs | 24 +- PARR.API/Validators/SubprocessValidator.cs | 6 +- .../TemplateActivatorRequestValidator.cs | 10 +- PARR.API/Validators/TnkRequestValidator.cs | 6 +- .../Validators/WeekendRequestValidator.cs | 6 +- PARR.API/Validators/WorkRequestValidator.cs | 6 +- .../Interfaces/IAgentHistoryRepository.cs | 9 + .../IDistributionPeriodRepository.cs | 9 + .../Interfaces/IOrderRepository.cs | 9 + .../Interfaces/IOrderStatusRepository.cs | 7 +- .../Interfaces/IParrComponentRepository.cs | 9 + .../Interfaces/IProcessRepository.cs | 9 + .../IRobotConfigurationRepository.cs | 8 +- .../IRobotHistoryLevelRepository.cs | 9 + .../Interfaces/IRobotHistoryRepository.cs | 9 + .../Interfaces/IRobotRepository.cs | 9 + .../Interfaces/IRobotStatusRepository.cs | 9 + .../Interfaces/IRoleRepository.cs | 9 + .../Interfaces/IStatusTemplateRepository.cs | 7 + .../Interfaces/ISubprocessRepository.cs | 9 + .../Interfaces/ITaskStatusRepository.cs | 7 + .../Interfaces/ITemplateHistoryRepository.cs | 9 + .../Interfaces/ITemplateRepository.cs | 8 +- .../ITemplateStatusTypeRepository.cs | 9 + .../Repositories/Interfaces/ITnkRepository.cs | 9 + .../Interfaces/IUserRepository.cs | 10 + .../Interfaces/IWeekendDayRepository.cs | 8 +- .../Interfaces/Job/IFieldFilterRepository.cs | 9 + .../Job/IJobAutoControlRepository.cs | 9 + .../Interfaces/Job/IJobGroupRepository.cs | 8 +- .../Interfaces/Job/IJobGroupTypeRepository.cs | 9 + .../Interfaces/Job/IJobRepository.cs | 8 + .../Job/IJobUnitFilterRepository.cs | 9 + .../Schedule/IEsppSchTypeConfigRepository.cs | 48 ++++ .../IEsppSchTypeScheduleRepository.cs | 10 + .../Schedule/IEsppSchTypeValueRepository.cs | 9 + .../IScheduleExcludeTypeCalendarRepository.cs | 9 + .../IScheduleExcludeTypeRepository.cs | 9 + ...cheduleResponseAreaTimeOffsetRepository.cs | 6 +- .../Interfaces/Unit/IUnitFieldRepository.cs | 10 + .../Unit/IUnitFieldValueRepository.cs | 10 + .../Interfaces/Unit/IUnitInUnitRepository.cs | 6 +- .../Interfaces/Unit/IUnitInValueRepository.cs | 6 +- .../Interfaces/Unit/IUnitKiiUnitRepository.cs | 9 + .../Unit/IUnitRegionalEkPtkGroupRepository.cs | 9 + .../Interfaces/Unit/IUnitRepository.cs | 9 + .../UnitFilterServiceIntegrationTests.cs | 18 +- .../TestDataGenerator.cs | 4 +- .../Implementations/ShortcodesServiceTests.cs | 12 +- .../Implementations/UnitFilterServiceTests.cs | 11 +- PARR.DAL.Tests/TestDataGenerator.cs | 4 +- .../EsppScheduleTransformServiceTests.cs | 8 +- PARR.DAL/Context/DataContext.cs | 22 +- PARR.DAL/DependencyInjection.cs | 193 +++++++++++++++ PARR.DAL/DomainModels/EsppScheduleDto.cs | 23 -- .../Implementations/MatchingStatusService.cs | 10 +- .../Shortcodes/IShortcodesService.cs | 2 +- .../Shortcodes/ShortcodesService.cs | 30 +-- .../UnitFilterService/IUnitFilterService.cs | 2 +- .../UnitFilterService/UnitFilterService.cs | 28 +-- .../Migrations/DataContextModelSnapshot.cs | 42 ++-- PARR.DAL/NextRunServices/INextRunService.cs | 4 +- PARR.DAL/NextRunServices/NextRunService.cs | 22 +- .../EsppScheduleTransformService.cs | 6 +- .../Subservices/TemplateDistributor.cs | 6 +- PARR.DAL/ParrDalInstaller.cs | 222 ------------------ .../Repositories/AgentHistoryRepository.cs | 14 ++ .../DistributionPeriodRepository.cs | 13 + .../EsppSchTypeConfigRepository.cs} | 10 +- .../EsppSchTypeScheduleRepository.cs} | 10 +- .../EsppSchTypeValueRepository.cs | 13 + .../Repositories/Job/FieldFilterRepository.cs | 13 + .../Job/JobAutoControlRepository.cs | 21 ++ .../Repositories/Job/JobGroupRepository.cs | 19 ++ .../Job/JobGroupTypeRepository.cs | 13 + PARR.DAL/Repositories/Job/JobRepository.cs | 39 +++ .../Job/JobUnitFilterRepository.cs | 13 + PARR.DAL/Repositories/OrderRepository.cs | 13 + .../OrderStatusRepository.cs} | 12 +- .../Repositories/ParrComponentRepository.cs | 21 ++ PARR.DAL/Repositories/ProcessRepository.cs | 14 ++ .../RobotConfigurationRepository.cs} | 10 +- .../RobotHistoryLevelRepository.cs | 21 ++ .../Repositories/RobotHistoryRepository.cs | 14 ++ PARR.DAL/Repositories/RobotRepository.cs | 21 ++ .../Repositories/RobotStatusRepository.cs | 21 ++ PARR.DAL/Repositories/RoleRepository.cs | 13 + .../ScheduleExcludeTypeCalendarRepository.cs | 13 + .../Schedule/ScheduleExcludeTypeRepository.cs | 13 + ...heduleResponseAreaTimeOffsetRepository.cs} | 12 +- .../Repositories/StatusTemplateRepository.cs | 20 ++ PARR.DAL/Repositories/SubprocessRepository.cs | 14 ++ PARR.DAL/Repositories/TaskStatusRepository.cs | 20 ++ .../Repositories/TemplateHistoryRepository.cs | 13 + .../TemplateRepository.cs} | 10 +- .../TemplateStatusTypeRepository.cs | 22 ++ PARR.DAL/Repositories/TnkRepository.cs | 14 ++ .../Unit/UnitFieldRepository.cs} | 10 +- .../Unit/UnitFieldValueRepository.cs} | 10 +- .../Unit/UnitInUnitRepository.cs} | 14 +- .../Unit/UnitInValueRepository.cs} | 14 +- .../Unit/UnitKiiUnitRepository.cs | 21 ++ .../Unit/UnitRegionalEkPtkGroupRepository.cs | 21 ++ .../Unit/UnitRepository.cs} | 10 +- .../UserRepository.cs} | 10 +- .../WeekendDayRepository.cs} | 12 +- .../Implementations/AgentHistoryService.cs | 14 -- .../DistributionPeriodService.cs | 13 - .../EsppSchTypeValueService.cs | 13 - .../Implementations/Job/FieldFilterService.cs | 12 - .../Job/JobAutoControlService.cs | 21 -- .../Implementations/Job/JobDetailsService.cs | 13 - .../Implementations/Job/JobGroupService.cs | 19 -- .../Job/JobGroupTypeService.cs | 13 - .../Implementations/Job/JobService.cs | 38 --- .../Services/Implementations/OrderService.cs | 13 - .../Implementations/ParrComponentService.cs | 21 -- .../Implementations/ProcessService.cs | 14 -- .../RobotHistoryLevelService.cs | 21 -- .../Implementations/RobotHistoryService.cs | 14 -- .../Services/Implementations/RobotService.cs | 21 -- .../Implementations/RobotStatusService.cs | 21 -- .../Services/Implementations/RoleService.cs | 13 - .../ScheduleExcludeTypeCalendarService.cs | 13 - .../Schedule/ScheduleExcludeTypeService.cs | 13 - .../Implementations/StatusTemplateService.cs | 21 -- .../Implementations/SubprocessService.cs | 14 -- .../Implementations/TaskStatusService.cs | 20 -- .../Implementations/TemplateHistoryService.cs | 13 - .../TemplateStatusTypeService.cs | 22 -- .../Services/Implementations/TnkService.cs | 14 -- .../Unit/UnitKiiUnitService.cs | 21 -- .../Unit/UnitRegionalEkPtkGroupService.cs | 21 -- .../Services/Interfaces/Base/IBaseService.cs | 41 ---- .../Interfaces/IAgentHistoryService.cs | 9 - .../Interfaces/IDistributionPeriodService.cs | 9 - .../Interfaces/IEsppSchTypeConfigService.cs | 25 -- .../Interfaces/IEsppSchTypeScheduleService.cs | 10 - .../Interfaces/IEsppSchTypeValueService.cs | 9 - PARR.DAL/Services/Interfaces/IOrderService.cs | 9 - .../Interfaces/IParrComponentService.cs | 9 - .../Services/Interfaces/IProcessService.cs | 9 - .../Interfaces/IRobotHistoryLevelService.cs | 9 - .../Interfaces/IRobotHistoryService.cs | 9 - PARR.DAL/Services/Interfaces/IRobotService.cs | 9 - .../Interfaces/IRobotStatusService.cs | 9 - PARR.DAL/Services/Interfaces/IRoleService.cs | 9 - .../Interfaces/IStatusTemplateService.cs | 9 - .../Services/Interfaces/ISubprocessService.cs | 9 - .../Services/Interfaces/ITaskStatusService.cs | 7 - .../Interfaces/ITemplateHistoryService.cs | 9 - .../Interfaces/ITemplateStatusTypeService.cs | 9 - PARR.DAL/Services/Interfaces/ITnkService.cs | 9 - PARR.DAL/Services/Interfaces/IUserService.cs | 10 - .../Interfaces/Job/IFieldFilterService.cs | 8 - .../Interfaces/Job/IJobAutoControlService.cs | 9 - .../Interfaces/Job/IJobDetailsService.cs | 8 - .../Interfaces/Job/IJobGroupTypeService.cs | 9 - .../Services/Interfaces/Job/IJobService.cs | 8 - .../Schedule/IScheduleExcludeTypeCalendar.cs | 9 - .../Schedule/IScheduleExcludeTypeService.cs | 9 - .../Interfaces/Unit/IUnitFieldService.cs | 10 - .../Interfaces/Unit/IUnitFieldValueService.cs | 10 - .../Interfaces/Unit/IUnitKiiUnitService.cs | 9 - .../Unit/IUnitRegionalEkPtkGroupService.cs | 9 - .../Services/Interfaces/Unit/IUnitService.cs | 9 - .../Entities}/AgentHistory.cs | 2 +- .../Entities}/AgentHistoryLevel.cs | 2 +- .../Entities}/DistributionPeriod.cs | 6 +- .../Entities}/DistributionPeriodType.cs | 5 +- .../Entities}/Job/Job.cs | 3 +- .../Entities}/Job/JobAutoControl.cs | 3 +- .../Entities}/Job/JobFieldFilter.cs | 5 +- .../Entities}/Job/JobGroup.cs | 7 +- .../Job/JobGroupDistributionConfig.cs | 3 +- .../Entities}/Job/JobGroupType.cs | 3 +- .../Entities}/Job/JobRelationshipFilter.cs | 5 +- .../Entities}/Job/JobUnitFilter.cs | 3 +- .../Models => PARR.Domain/Entities}/Order.cs | 2 +- .../Entities}/OrderStatus.cs | 2 +- .../Entities}/ParrComponent.cs | 2 +- .../Entities}/Process.cs | 2 +- .../Entities}/Removed/AppInWorkInWorkGroup.cs | 2 +- .../Entities}/Removed/Application.cs | 2 +- .../Entities}/Removed/ApplicationInHost.cs | 2 +- .../Entities}/Removed/ApplicationType.cs | 2 +- .../Entities}/Removed/ApplicationsInWork.cs | 2 +- .../Entities}/Removed/EkStatus.cs | 2 +- .../Entities}/Removed/Host.cs | 2 +- .../Entities}/Removed/ResponseArea.cs | 2 +- .../Entities}/Removed/WorkGroup.cs | 2 +- .../Models => PARR.Domain/Entities}/Robot.cs | 2 +- .../Entities}/RobotConfiguration.cs | 2 +- .../Entities}/RobotHistory.cs | 2 +- .../Entities}/RobotHistoryLevel.cs | 2 +- .../Entities}/RobotStatus.cs | 2 +- .../Models => PARR.Domain/Entities}/Role.cs | 2 +- .../Entities/Schedule}/EsppSchType.cs | 5 +- .../Entities/Schedule}/EsppSchTypeConfig.cs | 3 +- .../Entities/Schedule}/EsppSchTypeSchedule.cs | 5 +- .../Entities/Schedule}/EsppSchTypeValue.cs | 5 +- .../Entities/Schedule}/EsppSchValue.cs | 5 +- .../Entities}/Schedule/ScheduleExcludeType.cs | 5 +- .../Schedule/ScheduleExcludeTypeCalendar.cs | 5 +- .../ScheduleResponseAreaTimeOffset.cs | 3 +- .../Entities}/Setting.cs | 2 +- .../Entities}/Subprocess.cs | 2 +- .../Entities}/TaskStatus.cs | 2 +- .../Entities}/Template.cs | 2 +- .../Entities}/TemplateHistory.cs | 2 +- .../Entities}/TemplateStatusType.cs | 2 +- .../Models => PARR.Domain/Entities}/Tnk.cs | 2 +- .../Entities}/Unit/Unit.cs | 3 +- .../Entities}/Unit/UnitField.cs | 5 +- .../Unit/UnitFieldInUnitFieldValue.cs | 3 +- .../Entities}/Unit/UnitFieldValue.cs | 3 +- .../Entities}/Unit/UnitInField.cs | 3 +- .../Entities}/Unit/UnitInUnit.cs | 3 +- .../Entities}/Unit/UnitInValue.cs | 3 +- .../Entities}/Unit/UnitKiiUnit.cs | 3 +- .../Entities}/Unit/UnitRegionalEkPtkGroup.cs | 3 +- .../Entities}/UnitsInTemplate.cs | 3 +- .../Models => PARR.Domain/Entities}/User.cs | 2 +- .../Entities}/UsersInRole.cs | 2 +- .../Entities}/WeekendDay.cs | 3 +- .../ParrEsppOrderLoaderInstaller.cs | 2 +- .../Services/OrderItemService.cs | 16 +- PARR.EsppOrderManager/EsppOrderManager.cs | 8 +- .../ParrEsppOrderManagerInstaller.cs | 2 +- .../Services/EsppOrderService.cs | 2 +- .../Services/IEsppOrderService.cs | 2 +- PARR.EsppScheduleSync/ScheduleSyncher.cs | 16 +- PARR.EsppSync/EsppSyncInstaller.cs | 2 +- PARR.EsppSync/ISyncService.cs | 2 +- PARR.EsppSync/SyncService.cs | 8 +- .../EsppTemplateSyncInstaller.cs | 2 +- PARR.EsppTemplateSync/TemplateMQSyncer.cs | 2 +- .../JobAutoControlInstaller.cs | 2 +- PARR.JobAutoControl/JobAutoControlManager.cs | 8 +- PARR.Master/ParrMasterInstaller.cs | 2 +- PARR.Master/Services/OrderMasterService.cs | 12 +- PARR.MockData/Program.cs | 2 +- .../Services/TemplatesInitializer.cs | 20 +- PARR.NextRun/NextRunInstaller.cs | 2 +- PARR.NextRun/NextRunRabbitService.cs | 4 +- .../Services/INextRunUpdateService.cs | 2 +- PARR.NextRun/Services/NextRunUpdateService.cs | 12 +- PARR.TaskReconciliationWorker/Program.cs | 2 +- .../Services/ValidatorService.cs | 18 +- PARR.TemplateActivator/TemplateActivator.cs | 12 +- .../TemplateActivatorInstaller.cs | 2 +- .../Services/ValidatorService.cs | 9 +- .../TemplateDistributor.cs | 10 +- .../TemplateDistributorInstaller.cs | 2 +- .../Services/ValidatorService.cs | 18 +- .../TemplateGenerator.cs | 14 +- .../TemplateGeneratorWorkerInstaller.cs | 2 +- .../GroupedTemplateSynchronizer.cs | 34 +-- .../Implemetaions/JobGroupValidatorService.cs | 6 +- .../Implemetaions/JobValidatorService.cs | 6 +- .../SimpleTemplateSynchronizer.cs | 28 +-- .../Implemetaions/TemplateDeactivator.cs | 14 +- .../Implemetaions/TemplateNameNormalizer.cs | 2 +- .../Services/Implemetaions/TemplateReuser.cs | 8 +- .../Implemetaions/TemplateUpdaterMqSender.cs | 6 +- .../Interfaces/ITemplateDeactivator.cs | 2 +- .../Interfaces/ITemplateNameNormalizer.cs | 2 +- .../Services/Interfaces/ITemplateReuser.cs | 2 +- PARR.TemplateMatcher/TemplateMatcher.cs | 12 +- .../TemplateMatcherInstaller.cs | 2 +- .../Services/TemplateUpdaterService.cs | 24 +- .../TemplateUpdaterInstaller.cs | 2 +- PARR.Test/NextRun/NextRunTest.cs | 8 +- PARR.Test/Program.cs | 2 +- PARR.WorkloadBuilderWorker/Program.cs | 2 +- 356 files changed, 1817 insertions(+), 1985 deletions(-) create mode 100644 PARR.Core/Repositories/Interfaces/IAgentHistoryRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IDistributionPeriodRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IOrderRepository.cs rename PARR.DAL/Services/Interfaces/IOrderStatusService.cs => PARR.Core/Repositories/Interfaces/IOrderStatusRepository.cs (52%) create mode 100644 PARR.Core/Repositories/Interfaces/IParrComponentRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IProcessRepository.cs rename PARR.DAL/Services/Interfaces/IRobotConfigurationService.cs => PARR.Core/Repositories/Interfaces/IRobotConfigurationRepository.cs (91%) create mode 100644 PARR.Core/Repositories/Interfaces/IRobotHistoryLevelRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IRobotHistoryRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IRobotRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IRobotStatusRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IRoleRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IStatusTemplateRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/ISubprocessRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/ITaskStatusRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/ITemplateHistoryRepository.cs rename PARR.DAL/Services/Interfaces/ITemplateService.cs => PARR.Core/Repositories/Interfaces/ITemplateRepository.cs (85%) create mode 100644 PARR.Core/Repositories/Interfaces/ITemplateStatusTypeRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/ITnkRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/IUserRepository.cs rename PARR.DAL/Services/Interfaces/IWeekendDayService.cs => PARR.Core/Repositories/Interfaces/IWeekendDayRepository.cs (71%) create mode 100644 PARR.Core/Repositories/Interfaces/Job/IFieldFilterRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Job/IJobAutoControlRepository.cs rename PARR.DAL/Services/Interfaces/Job/IJobGroupService.cs => PARR.Core/Repositories/Interfaces/Job/IJobGroupRepository.cs (60%) create mode 100644 PARR.Core/Repositories/Interfaces/Job/IJobGroupTypeRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Job/IJobRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Job/IJobUnitFilterRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Schedule/IEsppSchTypeConfigRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Schedule/IEsppSchTypeScheduleRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Schedule/IEsppSchTypeValueRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Schedule/IScheduleExcludeTypeCalendarRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Schedule/IScheduleExcludeTypeRepository.cs rename PARR.DAL/Services/Interfaces/Schedule/IScheduleResponseAreaTimeOffsetService.cs => PARR.Core/Repositories/Interfaces/Schedule/IScheduleResponseAreaTimeOffsetRepository.cs (81%) create mode 100644 PARR.Core/Repositories/Interfaces/Unit/IUnitFieldRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Unit/IUnitFieldValueRepository.cs rename PARR.DAL/Services/Interfaces/Unit/IUnitInUnitService.cs => PARR.Core/Repositories/Interfaces/Unit/IUnitInUnitRepository.cs (83%) rename PARR.DAL/Services/Interfaces/Unit/IUnitInValueService.cs => PARR.Core/Repositories/Interfaces/Unit/IUnitInValueRepository.cs (90%) create mode 100644 PARR.Core/Repositories/Interfaces/Unit/IUnitKiiUnitRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Unit/IUnitRegionalEkPtkGroupRepository.cs create mode 100644 PARR.Core/Repositories/Interfaces/Unit/IUnitRepository.cs create mode 100644 PARR.DAL/DependencyInjection.cs delete mode 100644 PARR.DAL/DomainModels/EsppScheduleDto.cs delete mode 100644 PARR.DAL/ParrDalInstaller.cs create mode 100644 PARR.DAL/Repositories/AgentHistoryRepository.cs create mode 100644 PARR.DAL/Repositories/DistributionPeriodRepository.cs rename PARR.DAL/{Services/Implementations/EsppSchTypeConfigService.cs => Repositories/EsppSchTypeConfigRepository.cs} (91%) rename PARR.DAL/{Services/Implementations/EsppSchTypeScheduleService.cs => Repositories/EsppSchTypeScheduleRepository.cs} (65%) create mode 100644 PARR.DAL/Repositories/EsppSchTypeValueRepository.cs create mode 100644 PARR.DAL/Repositories/Job/FieldFilterRepository.cs create mode 100644 PARR.DAL/Repositories/Job/JobAutoControlRepository.cs create mode 100644 PARR.DAL/Repositories/Job/JobGroupRepository.cs create mode 100644 PARR.DAL/Repositories/Job/JobGroupTypeRepository.cs create mode 100644 PARR.DAL/Repositories/Job/JobRepository.cs create mode 100644 PARR.DAL/Repositories/Job/JobUnitFilterRepository.cs create mode 100644 PARR.DAL/Repositories/OrderRepository.cs rename PARR.DAL/{Services/Implementations/OrderStatusService.cs => Repositories/OrderStatusRepository.cs} (86%) create mode 100644 PARR.DAL/Repositories/ParrComponentRepository.cs create mode 100644 PARR.DAL/Repositories/ProcessRepository.cs rename PARR.DAL/{Services/Implementations/RobotConfigurationService.cs => Repositories/RobotConfigurationRepository.cs} (94%) create mode 100644 PARR.DAL/Repositories/RobotHistoryLevelRepository.cs create mode 100644 PARR.DAL/Repositories/RobotHistoryRepository.cs create mode 100644 PARR.DAL/Repositories/RobotRepository.cs create mode 100644 PARR.DAL/Repositories/RobotStatusRepository.cs create mode 100644 PARR.DAL/Repositories/RoleRepository.cs create mode 100644 PARR.DAL/Repositories/Schedule/ScheduleExcludeTypeCalendarRepository.cs create mode 100644 PARR.DAL/Repositories/Schedule/ScheduleExcludeTypeRepository.cs rename PARR.DAL/{Services/Implementations/Schedule/ScheduleResponseAreaTimeOffsetService.cs => Repositories/Schedule/ScheduleResponseAreaTimeOffsetRepository.cs} (85%) create mode 100644 PARR.DAL/Repositories/StatusTemplateRepository.cs create mode 100644 PARR.DAL/Repositories/SubprocessRepository.cs create mode 100644 PARR.DAL/Repositories/TaskStatusRepository.cs create mode 100644 PARR.DAL/Repositories/TemplateHistoryRepository.cs rename PARR.DAL/{Services/Implementations/TemplateService.cs => Repositories/TemplateRepository.cs} (96%) create mode 100644 PARR.DAL/Repositories/TemplateStatusTypeRepository.cs create mode 100644 PARR.DAL/Repositories/TnkRepository.cs rename PARR.DAL/{Services/Implementations/Unit/UnitFieldService.cs => Repositories/Unit/UnitFieldRepository.cs} (51%) rename PARR.DAL/{Services/Implementations/Unit/UnitFieldValueService.cs => Repositories/Unit/UnitFieldValueRepository.cs} (61%) rename PARR.DAL/{Services/Implementations/Unit/UnitInUnitService.cs => Repositories/Unit/UnitInUnitRepository.cs} (82%) rename PARR.DAL/{Services/Implementations/Unit/UnitInValueService.cs => Repositories/Unit/UnitInValueRepository.cs} (93%) create mode 100644 PARR.DAL/Repositories/Unit/UnitKiiUnitRepository.cs create mode 100644 PARR.DAL/Repositories/Unit/UnitRegionalEkPtkGroupRepository.cs rename PARR.DAL/{Services/Implementations/Unit/UnitService.cs => Repositories/Unit/UnitRepository.cs} (51%) rename PARR.DAL/{Services/Implementations/UserService.cs => Repositories/UserRepository.cs} (58%) rename PARR.DAL/{Services/Implementations/WeekendDayService.cs => Repositories/WeekendDayRepository.cs} (92%) delete mode 100644 PARR.DAL/Services/Implementations/AgentHistoryService.cs delete mode 100644 PARR.DAL/Services/Implementations/DistributionPeriodService.cs delete mode 100644 PARR.DAL/Services/Implementations/EsppSchTypeValueService.cs delete mode 100644 PARR.DAL/Services/Implementations/Job/FieldFilterService.cs delete mode 100644 PARR.DAL/Services/Implementations/Job/JobAutoControlService.cs delete mode 100644 PARR.DAL/Services/Implementations/Job/JobDetailsService.cs delete mode 100644 PARR.DAL/Services/Implementations/Job/JobGroupService.cs delete mode 100644 PARR.DAL/Services/Implementations/Job/JobGroupTypeService.cs delete mode 100644 PARR.DAL/Services/Implementations/Job/JobService.cs delete mode 100644 PARR.DAL/Services/Implementations/OrderService.cs delete mode 100644 PARR.DAL/Services/Implementations/ParrComponentService.cs delete mode 100644 PARR.DAL/Services/Implementations/ProcessService.cs delete mode 100644 PARR.DAL/Services/Implementations/RobotHistoryLevelService.cs delete mode 100644 PARR.DAL/Services/Implementations/RobotHistoryService.cs delete mode 100644 PARR.DAL/Services/Implementations/RobotService.cs delete mode 100644 PARR.DAL/Services/Implementations/RobotStatusService.cs delete mode 100644 PARR.DAL/Services/Implementations/RoleService.cs delete mode 100644 PARR.DAL/Services/Implementations/Schedule/ScheduleExcludeTypeCalendarService.cs delete mode 100644 PARR.DAL/Services/Implementations/Schedule/ScheduleExcludeTypeService.cs delete mode 100644 PARR.DAL/Services/Implementations/StatusTemplateService.cs delete mode 100644 PARR.DAL/Services/Implementations/SubprocessService.cs delete mode 100644 PARR.DAL/Services/Implementations/TaskStatusService.cs delete mode 100644 PARR.DAL/Services/Implementations/TemplateHistoryService.cs delete mode 100644 PARR.DAL/Services/Implementations/TemplateStatusTypeService.cs delete mode 100644 PARR.DAL/Services/Implementations/TnkService.cs delete mode 100644 PARR.DAL/Services/Implementations/Unit/UnitKiiUnitService.cs delete mode 100644 PARR.DAL/Services/Implementations/Unit/UnitRegionalEkPtkGroupService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Base/IBaseService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IAgentHistoryService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IDistributionPeriodService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IEsppSchTypeConfigService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IEsppSchTypeScheduleService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IEsppSchTypeValueService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IOrderService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IParrComponentService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IProcessService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IRobotHistoryLevelService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IRobotHistoryService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IRobotService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IRobotStatusService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IRoleService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IStatusTemplateService.cs delete mode 100644 PARR.DAL/Services/Interfaces/ISubprocessService.cs delete mode 100644 PARR.DAL/Services/Interfaces/ITaskStatusService.cs delete mode 100644 PARR.DAL/Services/Interfaces/ITemplateHistoryService.cs delete mode 100644 PARR.DAL/Services/Interfaces/ITemplateStatusTypeService.cs delete mode 100644 PARR.DAL/Services/Interfaces/ITnkService.cs delete mode 100644 PARR.DAL/Services/Interfaces/IUserService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Job/IFieldFilterService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Job/IJobAutoControlService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Job/IJobDetailsService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Job/IJobGroupTypeService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Job/IJobService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Schedule/IScheduleExcludeTypeCalendar.cs delete mode 100644 PARR.DAL/Services/Interfaces/Schedule/IScheduleExcludeTypeService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Unit/IUnitFieldService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Unit/IUnitFieldValueService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Unit/IUnitKiiUnitService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Unit/IUnitRegionalEkPtkGroupService.cs delete mode 100644 PARR.DAL/Services/Interfaces/Unit/IUnitService.cs rename {PARR.DAL/Models => PARR.Domain/Entities}/AgentHistory.cs (96%) rename {PARR.DAL/Models => PARR.Domain/Entities}/AgentHistoryLevel.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/DistributionPeriod.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/DistributionPeriodType.cs (84%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Job/Job.cs (98%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Job/JobAutoControl.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Job/JobFieldFilter.cs (92%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Job/JobGroup.cs (98%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Job/JobGroupDistributionConfig.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Job/JobGroupType.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Job/JobRelationshipFilter.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Job/JobUnitFilter.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Order.cs (98%) rename {PARR.DAL/Models => PARR.Domain/Entities}/OrderStatus.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/ParrComponent.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Process.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/AppInWorkInWorkGroup.cs (92%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/Application.cs (96%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/ApplicationInHost.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/ApplicationType.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/ApplicationsInWork.cs (99%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/EkStatus.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/Host.cs (97%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/ResponseArea.cs (92%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Removed/WorkGroup.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Robot.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/RobotConfiguration.cs (98%) rename {PARR.DAL/Models => PARR.Domain/Entities}/RobotHistory.cs (98%) rename {PARR.DAL/Models => PARR.Domain/Entities}/RobotHistoryLevel.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/RobotStatus.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Role.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities/Schedule}/EsppSchType.cs (89%) rename {PARR.DAL/Models => PARR.Domain/Entities/Schedule}/EsppSchTypeConfig.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities/Schedule}/EsppSchTypeSchedule.cs (88%) rename {PARR.DAL/Models => PARR.Domain/Entities/Schedule}/EsppSchTypeValue.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities/Schedule}/EsppSchValue.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Schedule/ScheduleExcludeType.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Schedule/ScheduleExcludeTypeCalendar.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Schedule/ScheduleResponseAreaTimeOffset.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Setting.cs (91%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Subprocess.cs (96%) rename {PARR.DAL/Models => PARR.Domain/Entities}/TaskStatus.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Template.cs (99%) rename {PARR.DAL/Models => PARR.Domain/Entities}/TemplateHistory.cs (97%) rename {PARR.DAL/Models => PARR.Domain/Entities}/TemplateStatusType.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Tnk.cs (96%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/Unit.cs (98%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/UnitField.cs (96%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/UnitFieldInUnitFieldValue.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/UnitFieldValue.cs (94%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/UnitInField.cs (92%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/UnitInUnit.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/UnitInValue.cs (95%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/UnitKiiUnit.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/Unit/UnitRegionalEkPtkGroup.cs (90%) rename {PARR.DAL/Models => PARR.Domain/Entities}/UnitsInTemplate.cs (92%) rename {PARR.DAL/Models => PARR.Domain/Entities}/User.cs (96%) rename {PARR.DAL/Models => PARR.Domain/Entities}/UsersInRole.cs (93%) rename {PARR.DAL/Models => PARR.Domain/Entities}/WeekendDay.cs (92%) diff --git a/PARR.AIHITMainSyncer/AihitMainSyncerInstaller.cs b/PARR.AIHITMainSyncer/AihitMainSyncerInstaller.cs index 4bebc554..7a883bb6 100644 --- a/PARR.AIHITMainSyncer/AihitMainSyncerInstaller.cs +++ b/PARR.AIHITMainSyncer/AihitMainSyncerInstaller.cs @@ -12,7 +12,7 @@ namespace PARR.AIHITMainSyncer { public static void InstallAihitMainSyncerServices(this IServiceCollection services, IConfiguration configuration) { - services.InstallDalServices(configuration); + services.AddDalServices(configuration); services.AddCoreServices(configuration); services.AddInfrastructureServices(configuration); diff --git a/PARR.AIHITMainSyncer/Services/SyncerService.cs b/PARR.AIHITMainSyncer/Services/SyncerService.cs index 00c40c51..46ebea35 100644 --- a/PARR.AIHITMainSyncer/Services/SyncerService.cs +++ b/PARR.AIHITMainSyncer/Services/SyncerService.cs @@ -3,9 +3,9 @@ using Microsoft.Extensions.Logging; using Newtonsoft.Json.Linq; using PARR.AIHITMainSyncer.Settings; using PARR.Core.Common.Interfaces; -using PARR.DAL.Models.Unit; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Rabbit.Messages; +using PARR.Domain.Entities.Unit; namespace PARR.AIHITMainSyncer.Services { @@ -13,17 +13,17 @@ namespace PARR.AIHITMainSyncer.Services { private readonly ILogger logger; private readonly ITransformService transformService; - private readonly IUnitService unitService; - private readonly IUnitFieldService unitFieldService; - private readonly IUnitFieldValueService unitFieldValueService; + private readonly IUnitRepository unitService; + private readonly IUnitFieldRepository unitFieldService; + private readonly IUnitFieldValueRepository unitFieldValueService; private readonly FieldValueReplacementsSettings fieldValueReplacementsSettings; public SyncerService( ILogger logger, ITransformService transformService, - IUnitService unitService, - IUnitFieldService unitFieldService, - IUnitFieldValueService unitFieldValueService, + IUnitRepository unitService, + IUnitFieldRepository unitFieldService, + IUnitFieldValueRepository unitFieldValueService, FieldValueReplacementsSettings fieldValueReplacementsSettings ) { diff --git a/PARR.AIHITRelationshipsSyncer/AihitRelationshpsSyncerInstaller.cs b/PARR.AIHITRelationshipsSyncer/AihitRelationshpsSyncerInstaller.cs index 5fe41ce6..4c6311c8 100644 --- a/PARR.AIHITRelationshipsSyncer/AihitRelationshpsSyncerInstaller.cs +++ b/PARR.AIHITRelationshipsSyncer/AihitRelationshpsSyncerInstaller.cs @@ -15,7 +15,7 @@ namespace PARR.AIHITRelationshipsSyncer { public static void InstallAihitRelationshpsSyncerServices(this IServiceCollection services, IConfiguration configuration) { - services.InstallDalServices(configuration); + services.AddDalServices(configuration); services.AddCoreServices(configuration); services.AddInfrastructureServices(configuration); diff --git a/PARR.AIHITRelationshipsSyncer/Services/Implementations/RelationshipsSyncService.cs b/PARR.AIHITRelationshipsSyncer/Services/Implementations/RelationshipsSyncService.cs index 61785cbb..25e6074b 100644 --- a/PARR.AIHITRelationshipsSyncer/Services/Implementations/RelationshipsSyncService.cs +++ b/PARR.AIHITRelationshipsSyncer/Services/Implementations/RelationshipsSyncService.cs @@ -3,20 +3,20 @@ using Microsoft.Extensions.Logging; using PARR.AIHITRelationshipsSyncer.Models; using PARR.AIHITRelationshipsSyncer.Services.Interfaces; using PARR.AIHITRelationshipsSyncer.Settings; -using PARR.DAL.Models.Unit; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces.Unit; +using PARR.Domain.Entities.Unit; namespace PARR.AIHITRelationshipsSyncer.Services.Implementations { internal class RelationshipsSyncService : IRelationshipsSyncService { private readonly ILogger logger; - private readonly IUnitService unitService; + private readonly IUnitRepository unitService; private readonly WorkerSettings workerSettings; public RelationshipsSyncService( ILogger logger, - IUnitService unitService, + IUnitRepository unitService, WorkerSettings workerSettings ) { diff --git a/PARR.API/Controllers/V1/AgentHistoryController.cs b/PARR.API/Controllers/V1/AgentHistoryController.cs index dd1831a5..99179b22 100644 --- a/PARR.API/Controllers/V1/AgentHistoryController.cs +++ b/PARR.API/Controllers/V1/AgentHistoryController.cs @@ -11,11 +11,11 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -25,22 +25,22 @@ namespace PARR.API.Controllers.V1 public class AgentHistoryController : BaseApiController { private readonly IValidator validator; - private readonly IAgentHistoryService agentHistoryService; + private readonly IAgentHistoryRepository agentHistoryService; private readonly IUriService uriService; private readonly IMapper mapper; - private readonly ITemplateService templateService; + private readonly ITemplateRepository templateService; private readonly IClientService clientService; - private readonly IUnitService unitService; + private readonly IUnitRepository unitService; private readonly ILogger logger; public AgentHistoryController( IValidator validator, - IAgentHistoryService agentHistoryService, + IAgentHistoryRepository agentHistoryService, IUriService uriService, IMapper mapper, - ITemplateService templateService, + ITemplateRepository templateService, IClientService clientService, - IUnitService unitService, + IUnitRepository unitService, ILogger logger ) { diff --git a/PARR.API/Controllers/V1/AgentTaskController.cs b/PARR.API/Controllers/V1/AgentTaskController.cs index 0821e303..1dad7a9c 100644 --- a/PARR.API/Controllers/V1/AgentTaskController.cs +++ b/PARR.API/Controllers/V1/AgentTaskController.cs @@ -4,8 +4,8 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Requests.Queries; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -17,15 +17,15 @@ namespace PARR.API.Controllers.V1 public class AgentTaskController : BaseApiController { private readonly IClientService clientService; - private readonly ITemplateService templateService; - private readonly IUnitService unitService; + private readonly ITemplateRepository templateService; + private readonly IUnitRepository unitService; //private readonly IEsppScheduleTransformService esppScheduleTransformService; private readonly ILogger logger; public AgentTaskController( IClientService clientService, - ITemplateService templateService, - IUnitService unitService, + ITemplateRepository templateService, + IUnitRepository unitService, //IEsppScheduleTransformService esppScheduleTransformService, ILogger logger ) diff --git a/PARR.API/Controllers/V1/DistributionPeriodController.cs b/PARR.API/Controllers/V1/DistributionPeriodController.cs index 939df0f1..42dcb78a 100644 --- a/PARR.API/Controllers/V1/DistributionPeriodController.cs +++ b/PARR.API/Controllers/V1/DistributionPeriodController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -17,11 +17,11 @@ namespace PARR.API.Controllers.V1 [Authorize(Roles = ParrRoles.Administrator.Role)] public class DistributionPeriodController : BaseApiController { - private readonly IDistributionPeriodService distributionPeriodService; + private readonly IDistributionPeriodRepository distributionPeriodService; private readonly IMapper mapper; public DistributionPeriodController( - IDistributionPeriodService distributionPeriodService, + IDistributionPeriodRepository distributionPeriodService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/EsppScheduleTypeScheduleController.cs b/PARR.API/Controllers/V1/EsppScheduleTypeScheduleController.cs index 0a2ef7ee..538c58cb 100644 --- a/PARR.API/Controllers/V1/EsppScheduleTypeScheduleController.cs +++ b/PARR.API/Controllers/V1/EsppScheduleTypeScheduleController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -18,11 +18,11 @@ namespace PARR.API.Controllers.V1 public class EsppScheduleTypeScheduleController : BaseApiController { private readonly IMapper mapper; - private readonly IEsppSchTypeScheduleService esppSchTypeScheduleService; + private readonly IEsppSchTypeScheduleRepository esppSchTypeScheduleService; public EsppScheduleTypeScheduleController( IMapper mapper, - IEsppSchTypeScheduleService esppSchTypeScheduleService + IEsppSchTypeScheduleRepository esppSchTypeScheduleService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/JobAutoControlController.cs b/PARR.API/Controllers/V1/JobAutoControlController.cs index d70ce5a5..813919ea 100644 --- a/PARR.API/Controllers/V1/JobAutoControlController.cs +++ b/PARR.API/Controllers/V1/JobAutoControlController.cs @@ -1,16 +1,5 @@ -using AutoMapper; -using FluentValidation; -using Microsoft.AspNetCore.Authorization; -using Microsoft.AspNetCore.Mvc; -using Microsoft.EntityFrameworkCore; -using PARR.API.Contracts.V1; -using PARR.API.Contracts.V1.Requests; -using PARR.API.Contracts.V1.Responses; -using PARR.API.Contracts.V1.Responses.Base; +using Microsoft.AspNetCore.Authorization; using PARR.API.Controllers.V1.Base; -using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 diff --git a/PARR.API/Controllers/V1/JobController.cs b/PARR.API/Controllers/V1/JobController.cs index 567c4ca7..8de9cd89 100644 --- a/PARR.API/Controllers/V1/JobController.cs +++ b/PARR.API/Controllers/V1/JobController.cs @@ -12,20 +12,19 @@ using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; using PARR.API.Settings; -using PARR.BLL.Helpers; using PARR.Core.Common.Helpers; using PARR.Core.Common.Interfaces.RabbitServices; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.DAL.DomainServices.Interfaces; using PARR.DAL.DomainServices.UnitFilterService; using PARR.DAL.Extensions; -using PARR.DAL.Models.Job; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Job; -using PARR.DAL.Services.Interfaces.Unit; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Rabbit.Messages; using PARR.Domain.Common.Roles; using PARR.Domain.Entities.Base.History; +using PARR.Domain.Entities.Job; using PARR.Domain.Enums; namespace PARR.API.Controllers.V1 @@ -39,29 +38,29 @@ namespace PARR.API.Controllers.V1 private readonly ILogger logger; private readonly IMapper mapper; private readonly IUriService uriService; - private readonly IJobService jobService; - private readonly ITemplateService templateService; + private readonly IJobRepository jobService; + private readonly ITemplateRepository templateService; private readonly IValidator jobValidator; private readonly IRabbitService mqService; private readonly MqSettings mqSettings; private readonly IClientService clientService; - private readonly IJobAutoControlService jobAutoControlService; + private readonly IJobAutoControlRepository jobAutoControlService; private readonly IMatchingStatusService matchingStatusService; public JobController( ILogger logger, IMapper mapper, IUriService uriService, - IJobService jobService, - ITemplateService templateService, - IJobGroupService jobGroupService, + IJobRepository jobService, + ITemplateRepository templateService, + IJobGroupRepository jobGroupService, IValidator jobValidator, IUnitFilterService unitFilterService, - IUnitService unitService, + IUnitRepository unitService, IRabbitService mqService, MqSettings mqSettings, IClientService clientService, - IJobAutoControlService jobAutoControlService, + IJobAutoControlRepository jobAutoControlService, IMatchingStatusService matchingStatusService ) { diff --git a/PARR.API/Controllers/V1/JobGroupController.cs b/PARR.API/Controllers/V1/JobGroupController.cs index 2192c8c9..a24ef402 100644 --- a/PARR.API/Controllers/V1/JobGroupController.cs +++ b/PARR.API/Controllers/V1/JobGroupController.cs @@ -12,19 +12,17 @@ using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; using PARR.API.Settings; -using PARR.BLL.Helpers; using PARR.Core.Common.Helpers; using PARR.Core.Common.Interfaces.RabbitServices; +using PARR.Core.Repositories.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.DAL.DomainServices.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Models.Job; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Job; -using PARR.DAL.Services.Interfaces.Schedule; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Rabbit.Messages; using PARR.Domain.Common.Roles; using PARR.Domain.Entities.Base.History; +using PARR.Domain.Entities.Job; +using PARR.Domain.Entities.Schedule; using PARR.Domain.Enums; namespace PARR.API.Controllers.V1 @@ -38,13 +36,13 @@ namespace PARR.API.Controllers.V1 private readonly ILogger logger; private readonly IMapper mapper; private readonly IUriService uriService; - private readonly IJobGroupService groupService; - private readonly IJobService jobService; - private readonly IEsppSchTypeConfigService esppConfigService; + private readonly IJobGroupRepository groupService; + private readonly IJobRepository jobService; + private readonly IEsppSchTypeConfigRepository esppConfigService; private readonly IValidator validator; - private readonly IJobGroupTypeService jobGroupTypeService; + private readonly IJobGroupTypeRepository jobGroupTypeService; private readonly IMatchingStatusService matchingStatusService; - private readonly IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService; + private readonly IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService; private readonly IRabbitService mqService; private readonly MqSettings mqSettings; @@ -52,13 +50,13 @@ namespace PARR.API.Controllers.V1 ILogger logger, IMapper mapper, IUriService uriService, - IJobGroupService groupService, - IJobService jobService, - IEsppSchTypeConfigService esppConfigService, + IJobGroupRepository groupService, + IJobRepository jobService, + IEsppSchTypeConfigRepository esppConfigService, IValidator validator, - IJobGroupTypeService jobGroupTypeService, + IJobGroupTypeRepository jobGroupTypeService, IMatchingStatusService matchingStatusService, - IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService, + IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService, IRabbitService mqService, MqSettings mqSettings ) diff --git a/PARR.API/Controllers/V1/JobGroupTypeController.cs b/PARR.API/Controllers/V1/JobGroupTypeController.cs index 1f9de449..24f4797a 100644 --- a/PARR.API/Controllers/V1/JobGroupTypeController.cs +++ b/PARR.API/Controllers/V1/JobGroupTypeController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Job; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -17,11 +17,11 @@ namespace PARR.API.Controllers.V1 [Authorize(Roles = ParrRoles.Administrator.Role)] public class JobGroupTypeController : BaseApiController { - private readonly IJobGroupTypeService jobGroupTypeService; + private readonly IJobGroupTypeRepository jobGroupTypeService; private readonly IMapper mapper; public JobGroupTypeController( - IJobGroupTypeService jobGroupTypeService, + IJobGroupTypeRepository jobGroupTypeService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/JobGroupUpdateNextRunController.cs b/PARR.API/Controllers/V1/JobGroupUpdateNextRunController.cs index 9241fbc2..cb00cbf0 100644 --- a/PARR.API/Controllers/V1/JobGroupUpdateNextRunController.cs +++ b/PARR.API/Controllers/V1/JobGroupUpdateNextRunController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Settings; using PARR.Core.Common.Interfaces.RabbitServices; -using PARR.DAL.Services.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Job; using PARR.Domain.Common.Rabbit.Messages; using PARR.Domain.Common.Roles; using PARR.Domain.Entities.Base.History; @@ -22,12 +22,12 @@ namespace PARR.API.Controllers.V1 { private readonly IRabbitService mqService; private readonly MqSettings mqSettings; - private readonly IJobGroupService jobGroupService; + private readonly IJobGroupRepository jobGroupService; public JobGroupUpdateNextRunController( IRabbitService mqService, MqSettings mqSettings, - IJobGroupService jobGroupService + IJobGroupRepository jobGroupService ) { this.mqService = mqService; diff --git a/PARR.API/Controllers/V1/JobUnitPreviewController.cs b/PARR.API/Controllers/V1/JobUnitPreviewController.cs index 1654bd99..00ee45a5 100644 --- a/PARR.API/Controllers/V1/JobUnitPreviewController.cs +++ b/PARR.API/Controllers/V1/JobUnitPreviewController.cs @@ -8,11 +8,11 @@ using PARR.API.Contracts.V1.Requests; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; +using PARR.Core.Repositories.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.DAL.DomainServices.UnitFilterService; -using PARR.DAL.Services.Interfaces.Job; -using PARR.DAL.Services.Interfaces.Unit; using PARR.Domain.Common.Roles; -using Job = PARR.DAL.Models.Job.Job; +using Job = PARR.Domain.Entities.Job.Job; namespace PARR.API.Controllers.V1 { @@ -25,16 +25,16 @@ namespace PARR.API.Controllers.V1 private readonly ILogger logger; private readonly IUnitFilterService unitFilterService; private readonly IValidator jobValidator; - private readonly IUnitService unitService; - private readonly IJobGroupService jobGroupService; + private readonly IUnitRepository unitService; + private readonly IJobGroupRepository jobGroupService; private readonly IMapper mapper; public JobUnitPreviewController( ILogger logger, IUnitFilterService unitFilterService, IValidator jobValidator, - IUnitService unitService, - IJobGroupService jobGroupService, + IUnitRepository unitService, + IJobGroupRepository jobGroupService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/KiiUnitController.cs b/PARR.API/Controllers/V1/KiiUnitController.cs index acfb4637..3cbe8e75 100644 --- a/PARR.API/Controllers/V1/KiiUnitController.cs +++ b/PARR.API/Controllers/V1/KiiUnitController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -18,11 +18,11 @@ namespace PARR.API.Controllers.V1 public class KiiUnitController : BaseApiController { private readonly IMapper mapper; - private readonly IUnitKiiUnitService unitKiiUnitService; + private readonly IUnitKiiUnitRepository unitKiiUnitService; public KiiUnitController( IMapper mapper, - IUnitKiiUnitService unitKiiUnitService + IUnitKiiUnitRepository unitKiiUnitService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/OrderController.cs b/PARR.API/Controllers/V1/OrderController.cs index 6306d8c2..4e244169 100644 --- a/PARR.API/Controllers/V1/OrderController.cs +++ b/PARR.API/Controllers/V1/OrderController.cs @@ -8,10 +8,10 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -22,11 +22,11 @@ namespace PARR.API.Controllers.V1 public class OrderController : BaseApiController { private readonly IMapper mapper; - private readonly IOrderService orderService; + private readonly IOrderRepository orderService; public OrderController( IMapper mapper, - IOrderService orderService + IOrderRepository orderService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/ProcessController.cs b/PARR.API/Controllers/V1/ProcessController.cs index fedb56d6..b3dd3be8 100644 --- a/PARR.API/Controllers/V1/ProcessController.cs +++ b/PARR.API/Controllers/V1/ProcessController.cs @@ -11,10 +11,10 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -26,14 +26,14 @@ namespace PARR.API.Controllers.V1 { private readonly ILogger logger; private readonly IMapper mapper; - private readonly IProcessService processService; + private readonly IProcessRepository processService; private readonly IValidator validator; private readonly IUriService uriService; public ProcessController( ILogger logger, IMapper mapper, - IProcessService processService, + IProcessRepository processService, IValidator validator, IUriService uriService ) diff --git a/PARR.API/Controllers/V1/RegionalEkPtkGroupController.cs b/PARR.API/Controllers/V1/RegionalEkPtkGroupController.cs index 07f20ab3..0c753d84 100644 --- a/PARR.API/Controllers/V1/RegionalEkPtkGroupController.cs +++ b/PARR.API/Controllers/V1/RegionalEkPtkGroupController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -18,11 +18,11 @@ namespace PARR.API.Controllers.V1 public class RegionalEkPtkGroupController : BaseApiController { private readonly IMapper mapper; - private readonly IUnitRegionalEkPtkGroupService unitRegionalEkPtkGroupService; + private readonly IUnitRegionalEkPtkGroupRepository unitRegionalEkPtkGroupService; public RegionalEkPtkGroupController( IMapper mapper, - IUnitRegionalEkPtkGroupService unitRegionalEkPtkGroupService + IUnitRegionalEkPtkGroupRepository unitRegionalEkPtkGroupService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/RobotController.cs b/PARR.API/Controllers/V1/RobotController.cs index 7fb8784d..34617992 100644 --- a/PARR.API/Controllers/V1/RobotController.cs +++ b/PARR.API/Controllers/V1/RobotController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -15,11 +15,11 @@ namespace PARR.API.Controllers.V1 public class RobotController : BaseApiController { private readonly IMapper mapper; - private readonly IRobotService robotService; + private readonly IRobotRepository robotService; public RobotController( IMapper mapper, - IRobotService robotService + IRobotRepository robotService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/RobotHistoryController.cs b/PARR.API/Controllers/V1/RobotHistoryController.cs index b1676e7e..721297c1 100644 --- a/PARR.API/Controllers/V1/RobotHistoryController.cs +++ b/PARR.API/Controllers/V1/RobotHistoryController.cs @@ -11,10 +11,10 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -25,19 +25,19 @@ namespace PARR.API.Controllers.V1 private readonly IMapper mapper; private readonly IUriService uriService; - private readonly IRobotHistoryService robotHistoryService; - private readonly IRobotConfigurationService robotConfigurationService; + private readonly IRobotHistoryRepository robotHistoryService; + private readonly IRobotConfigurationRepository robotConfigurationService; private readonly IClientService clientService; - private readonly IUserService userService; + private readonly IUserRepository userService; public RobotHistoryController( IValidator validator, IMapper mapper, IUriService uriService, - IRobotHistoryService robotHistoryService, - IRobotConfigurationService robotConfigurationService, + IRobotHistoryRepository robotHistoryService, + IRobotConfigurationRepository robotConfigurationService, IClientService clientService, - IUserService userService + IUserRepository userService ) { this.validator = validator; diff --git a/PARR.API/Controllers/V1/RobotHistoryLevelController.cs b/PARR.API/Controllers/V1/RobotHistoryLevelController.cs index b94e6a48..2bdfad3e 100644 --- a/PARR.API/Controllers/V1/RobotHistoryLevelController.cs +++ b/PARR.API/Controllers/V1/RobotHistoryLevelController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -15,11 +15,11 @@ namespace PARR.API.Controllers.V1 public class RobotHistoryLevelController : BaseApiController { private readonly IMapper mapper; - private readonly IRobotHistoryLevelService robotHistoryLevelService; + private readonly IRobotHistoryLevelRepository robotHistoryLevelService; public RobotHistoryLevelController( IMapper mapper, - IRobotHistoryLevelService robotHistoryLevelService + IRobotHistoryLevelRepository robotHistoryLevelService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/RobotTaskController.cs b/PARR.API/Controllers/V1/RobotTaskController.cs index 6ada7e69..567fcda2 100644 --- a/PARR.API/Controllers/V1/RobotTaskController.cs +++ b/PARR.API/Controllers/V1/RobotTaskController.cs @@ -9,12 +9,12 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.BLL.Helpers; +using PARR.Core.Repositories.Interfaces; using PARR.DAL.Contracts; using PARR.DAL.DomainServices.Shortcodes; -using PARR.DAL.Models; using PARR.DAL.NextRunServices; -using PARR.DAL.Services.Interfaces; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; using PARR.Domain.Entities.Base.History; using PARR.Domain.Enums; @@ -25,11 +25,11 @@ namespace PARR.API.Controllers.V1 { private readonly IMapper mapper; private readonly SettingsFromDb settingsFromDb; - private readonly IRobotConfigurationService robotConfigurationService; + private readonly IRobotConfigurationRepository robotConfigurationService; //private readonly IEsppScheduleTransformService esppScheduleTransformService; private readonly ILogger logger; private readonly IClientService clientService; - private readonly IRobotHistoryService robotHistoryService; + private readonly IRobotHistoryRepository robotHistoryService; private readonly IShortcodesService shortcodesService; private readonly INextRunService nextRunService; //private readonly IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService; @@ -37,11 +37,11 @@ namespace PARR.API.Controllers.V1 public RobotTaskController( IMapper mapper, SettingsFromDb settingsFromDb, - IRobotConfigurationService robotConfigurationService, + IRobotConfigurationRepository robotConfigurationService, //IEsppScheduleTransformService esppScheduleTransformService, ILogger logger, IClientService clientService, - IRobotHistoryService robotHistoryService, + IRobotHistoryRepository robotHistoryService, IShortcodesService shortcodesService, INextRunService nextRunService //IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService diff --git a/PARR.API/Controllers/V1/RobotTaskRobotStatusController.cs b/PARR.API/Controllers/V1/RobotTaskRobotStatusController.cs index cc3c5468..b212c0a0 100644 --- a/PARR.API/Controllers/V1/RobotTaskRobotStatusController.cs +++ b/PARR.API/Controllers/V1/RobotTaskRobotStatusController.cs @@ -8,10 +8,9 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; -using PARR.DAL.Contracts; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; using PARR.Domain.Enums; namespace PARR.API.Controllers.V1 @@ -19,14 +18,14 @@ namespace PARR.API.Controllers.V1 [Authorize(Roles = ParrRoles.EsppRobot.RoleOrAdmin)] public class RobotTaskRobotStatusController : BaseApiController { - private readonly IRobotConfigurationService robotConfigurationService; - private readonly IRobotHistoryService robotHistoryService; + private readonly IRobotConfigurationRepository robotConfigurationService; + private readonly IRobotHistoryRepository robotHistoryService; private readonly IMapper mapper; private readonly IClientService clientService; public RobotTaskRobotStatusController( - IRobotConfigurationService robotConfigurationService, - IRobotHistoryService robotHistoryService, + IRobotConfigurationRepository robotConfigurationService, + IRobotHistoryRepository robotHistoryService, IMapper mapper, IClientService clientService ) diff --git a/PARR.API/Controllers/V1/RoleController.cs b/PARR.API/Controllers/V1/RoleController.cs index 92b28697..2fe47544 100644 --- a/PARR.API/Controllers/V1/RoleController.cs +++ b/PARR.API/Controllers/V1/RoleController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -14,11 +14,11 @@ namespace PARR.API.Controllers.V1 [Authorize(Roles = ParrRoles.Administrator.Role)] public class RoleController : BaseApiController { - private readonly IRoleService roleService; + private readonly IRoleRepository roleService; private readonly IMapper mapper; public RoleController( - IRoleService roleService, + IRoleRepository roleService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/ScheduleExcludeTypeCalendarController.cs b/PARR.API/Controllers/V1/ScheduleExcludeTypeCalendarController.cs index 64a3b1cd..e58e3963 100644 --- a/PARR.API/Controllers/V1/ScheduleExcludeTypeCalendarController.cs +++ b/PARR.API/Controllers/V1/ScheduleExcludeTypeCalendarController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces.Schedule; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -18,11 +18,11 @@ namespace PARR.API.Controllers.V1 public class ScheduleExcludeTypeCalendarController : BaseApiController { private readonly IMapper mapper; - private readonly IScheduleExcludeTypeCalendarService scheduleExcludeTypeCalendarService; + private readonly IScheduleExcludeTypeCalendarRepository scheduleExcludeTypeCalendarService; public ScheduleExcludeTypeCalendarController( IMapper mapper, - IScheduleExcludeTypeCalendarService scheduleExcludeTypeCalendarService + IScheduleExcludeTypeCalendarRepository scheduleExcludeTypeCalendarService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/ScheduleExcludeTypeController.cs b/PARR.API/Controllers/V1/ScheduleExcludeTypeController.cs index 3fa1afa7..74890a23 100644 --- a/PARR.API/Controllers/V1/ScheduleExcludeTypeController.cs +++ b/PARR.API/Controllers/V1/ScheduleExcludeTypeController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces.Schedule; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -18,11 +18,11 @@ namespace PARR.API.Controllers.V1 public class ScheduleExcludeTypeController : BaseApiController { private readonly IMapper mapper; - private readonly IScheduleExcludeTypeService scheduleExcludeTypeService; + private readonly IScheduleExcludeTypeRepository scheduleExcludeTypeService; public ScheduleExcludeTypeController( IMapper mapper, - IScheduleExcludeTypeService scheduleExcludeTypeService + IScheduleExcludeTypeRepository scheduleExcludeTypeService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/ShortcodeApplyController.cs b/PARR.API/Controllers/V1/ShortcodeApplyController.cs index cdf209cc..7fa0251a 100644 --- a/PARR.API/Controllers/V1/ShortcodeApplyController.cs +++ b/PARR.API/Controllers/V1/ShortcodeApplyController.cs @@ -5,8 +5,8 @@ using PARR.API.Contracts.V1.Requests; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; +using PARR.Core.Repositories.Interfaces; using PARR.DAL.DomainServices.Shortcodes; -using PARR.DAL.Services.Interfaces; namespace PARR.API.Controllers.V1 { @@ -14,12 +14,12 @@ namespace PARR.API.Controllers.V1 { private readonly ILogger logger; private readonly IShortcodesService shortcodesService; - private readonly ITemplateService templateService; + private readonly ITemplateRepository templateService; public ShortcodeApplyController( ILogger logger, IShortcodesService shortcodesService, - ITemplateService templateService + ITemplateRepository templateService ) { this.logger = logger; diff --git a/PARR.API/Controllers/V1/Statistics/StatOrderController.cs b/PARR.API/Controllers/V1/Statistics/StatOrderController.cs index 9138925f..e90fe970 100644 --- a/PARR.API/Controllers/V1/Statistics/StatOrderController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatOrderController.cs @@ -9,8 +9,8 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Helpers; +using PARR.Core.Repositories.Interfaces; using PARR.DAL.NextRunServices; -using PARR.DAL.Services.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1.Statistics @@ -21,14 +21,14 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.Administrator.Role)] public class StatOrderController : BaseApiController { - private readonly IOrderService orderService; - private readonly IOrderStatusService orderStatusService; + private readonly IOrderRepository orderService; + private readonly IOrderStatusRepository orderStatusService; private readonly IMapper mapper; private readonly INextRunService nextRunService; public StatOrderController( - IOrderService orderService, - IOrderStatusService orderStatusService, + IOrderRepository orderService, + IOrderStatusRepository orderStatusService, IMapper mapper, INextRunService nextRunService ) diff --git a/PARR.API/Controllers/V1/Statistics/StatResponseAreaWorkLoadController.cs b/PARR.API/Controllers/V1/Statistics/StatResponseAreaWorkLoadController.cs index cfe23499..a18c7e65 100644 --- a/PARR.API/Controllers/V1/Statistics/StatResponseAreaWorkLoadController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatResponseAreaWorkLoadController.cs @@ -10,7 +10,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1.Statistics @@ -21,13 +21,13 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.EsppRobot.RoleOrAdmin)] public class StatResponseAreaWorkLoadController : BaseApiController { - private readonly ITemplateService templateService; + private readonly ITemplateRepository templateService; //private readonly IResponseAreaService responseAreaService; private readonly IMapper mapper; private readonly IWorkLoadService workLoadService; public StatResponseAreaWorkLoadController( - ITemplateService templateService, + ITemplateRepository templateService, //IResponseAreaService responseAreaService, IMapper mapper, IWorkLoadService workLoadService diff --git a/PARR.API/Controllers/V1/Statistics/StatRobotHistoryController.cs b/PARR.API/Controllers/V1/Statistics/StatRobotHistoryController.cs index 66fd9138..2e9db8c4 100644 --- a/PARR.API/Controllers/V1/Statistics/StatRobotHistoryController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatRobotHistoryController.cs @@ -10,9 +10,9 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Helpers; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1.Statistics { @@ -22,13 +22,13 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.Administrator.Role)] public class StatRobotHistoryController : BaseApiController { - private readonly IRobotHistoryService robotHistoryService; - private readonly IRobotHistoryLevelService robotHistoryLevelService; + private readonly IRobotHistoryRepository robotHistoryService; + private readonly IRobotHistoryLevelRepository robotHistoryLevelService; private readonly IMapper mapper; public StatRobotHistoryController( - IRobotHistoryService robotHistoryService, - IRobotHistoryLevelService robotHistoryLevelService, + IRobotHistoryRepository robotHistoryService, + IRobotHistoryLevelRepository robotHistoryLevelService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/Statistics/StatRobotStateController.cs b/PARR.API/Controllers/V1/Statistics/StatRobotStateController.cs index b6fc9dae..f6f98519 100644 --- a/PARR.API/Controllers/V1/Statistics/StatRobotStateController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatRobotStateController.cs @@ -15,7 +15,7 @@ using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.API.Settings; using PARR.Core.Common.Interfaces; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; using PARR.Domain.Enums; using PARR.Domain.Settings; @@ -33,7 +33,7 @@ namespace PARR.API.Controllers.V1.Statistics private readonly InfluxDbSettings influxDbSettings; private readonly MonitoringSettings monitoringSettings; private readonly IClientService clientService; - private readonly IUserService userService; + private readonly IUserRepository userService; private readonly IMapper mapper; public StatRobotStateController( @@ -42,7 +42,7 @@ namespace PARR.API.Controllers.V1.Statistics InfluxDbSettings influxDbSettings, MonitoringSettings monitoringSettings, IClientService clientService, - IUserService userService, + IUserRepository userService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/Statistics/StatRobotStatusController.cs b/PARR.API/Controllers/V1/Statistics/StatRobotStatusController.cs index e8ff8948..00982235 100644 --- a/PARR.API/Controllers/V1/Statistics/StatRobotStatusController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatRobotStatusController.cs @@ -7,7 +7,7 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1.Statistics @@ -18,15 +18,15 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.Administrator.Role)] public class StatRobotStatusController : BaseApiController { - private readonly IRobotService robotService; - private readonly IRobotConfigurationService robotConfigurationService; - private readonly IRobotStatusService robotStatusService; + private readonly IRobotRepository robotService; + private readonly IRobotConfigurationRepository robotConfigurationService; + private readonly IRobotStatusRepository robotStatusService; private readonly IMapper mapper; public StatRobotStatusController( - IRobotService robotService, - IRobotConfigurationService robotConfigurationService, - IRobotStatusService robotStatusService, + IRobotRepository robotService, + IRobotConfigurationRepository robotConfigurationService, + IRobotStatusRepository robotStatusService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/Statistics/StatRobotTaskController.cs b/PARR.API/Controllers/V1/Statistics/StatRobotTaskController.cs index 3fa866c6..da615373 100644 --- a/PARR.API/Controllers/V1/Statistics/StatRobotTaskController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatRobotTaskController.cs @@ -8,8 +8,8 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; +using PARR.Core.Repositories.Interfaces; using PARR.DAL.Contracts; -using PARR.DAL.Services.Interfaces; using PARR.Domain.Common.Roles; using PARR.Domain.Enums; @@ -21,17 +21,17 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.Administrator.Role)] public class StatRobotTaskController : BaseApiController { - private readonly IRobotService robotService; - private readonly IRobotConfigurationService robotConfigurationService; - private readonly ITaskStatusService taskStatusService; - private readonly IRobotHistoryService robotHistoryService; + private readonly IRobotRepository robotService; + private readonly IRobotConfigurationRepository robotConfigurationService; + private readonly ITaskStatusRepository taskStatusService; + private readonly IRobotHistoryRepository robotHistoryService; private readonly IMapper mapper; public StatRobotTaskController( - IRobotService robotService, - IRobotConfigurationService robotConfigurationService, - ITaskStatusService taskStatusService, - IRobotHistoryService robotHistoryService, + IRobotRepository robotService, + IRobotConfigurationRepository robotConfigurationService, + ITaskStatusRepository taskStatusService, + IRobotHistoryRepository robotHistoryService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/Statistics/StatStatusTypeTemplates.cs b/PARR.API/Controllers/V1/Statistics/StatStatusTypeTemplates.cs index a72f11a1..0073e851 100644 --- a/PARR.API/Controllers/V1/Statistics/StatStatusTypeTemplates.cs +++ b/PARR.API/Controllers/V1/Statistics/StatStatusTypeTemplates.cs @@ -7,7 +7,7 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1.Statistics @@ -18,13 +18,13 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.Administrator.Role)] public class StatStatusTypeTemplates : BaseApiController { - private readonly ITemplateService templateService; - private readonly ITemplateStatusTypeService templateStatusTypeService; + private readonly ITemplateRepository templateService; + private readonly ITemplateStatusTypeRepository templateStatusTypeService; private readonly IMapper mapper; public StatStatusTypeTemplates( - ITemplateService templateService, - ITemplateStatusTypeService templateStatusTypeService, + ITemplateRepository templateService, + ITemplateStatusTypeRepository templateStatusTypeService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/Statistics/StatTemplateAutoControlController.cs b/PARR.API/Controllers/V1/Statistics/StatTemplateAutoControlController.cs index eaef29fc..1247869b 100644 --- a/PARR.API/Controllers/V1/Statistics/StatTemplateAutoControlController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatTemplateAutoControlController.cs @@ -6,21 +6,21 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Helpers; +using PARR.Core.Repositories.Interfaces; using PARR.DAL.NextRunServices; -using PARR.DAL.Services.Interfaces; using PARR.Domain.Enums; namespace PARR.API.Controllers.V1.Statistics { public class StatTemplateAutoControlController : BaseApiController { - private readonly ITemplateService templateService; - private readonly ITemplateHistoryService templateHistoryService; + private readonly ITemplateRepository templateService; + private readonly ITemplateHistoryRepository templateHistoryService; private readonly INextRunService nextRunService; public StatTemplateAutoControlController( - ITemplateService templateService, - ITemplateHistoryService templateHistoryService, + ITemplateRepository templateService, + ITemplateHistoryRepository templateHistoryService, INextRunService nextRunService ) { diff --git a/PARR.API/Controllers/V1/Statistics/StatTemplateController.cs b/PARR.API/Controllers/V1/Statistics/StatTemplateController.cs index 98418b75..f6ade931 100644 --- a/PARR.API/Controllers/V1/Statistics/StatTemplateController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatTemplateController.cs @@ -7,9 +7,9 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Helpers; +using PARR.Core.Repositories.Interfaces; using PARR.DAL.Contracts; using PARR.DAL.NextRunServices; -using PARR.DAL.Services.Interfaces; using PARR.Domain.Common.Roles; using PARR.Domain.Enums; @@ -21,11 +21,11 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.Administrator.Role)] public class StatTemplateController : BaseApiController { - private readonly ITemplateService templateService; + private readonly ITemplateRepository templateService; private readonly INextRunService nextRunService; public StatTemplateController( - ITemplateService templateService, + ITemplateRepository templateService, INextRunService nextRunService ) { diff --git a/PARR.API/Controllers/V1/Statistics/StatTemplateDistributionController.cs b/PARR.API/Controllers/V1/Statistics/StatTemplateDistributionController.cs index 9215591c..00f15a6d 100644 --- a/PARR.API/Controllers/V1/Statistics/StatTemplateDistributionController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatTemplateDistributionController.cs @@ -8,14 +8,14 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.DAL.DomainServices.Shortcodes; -using PARR.DAL.Models; -using PARR.DAL.Models.Job; using PARR.DAL.NextRunServices; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Job; -using PARR.DAL.Services.Interfaces.Schedule; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; +using PARR.Domain.Entities.Job; using PARR.Domain.Enums; namespace PARR.API.Controllers.V1.Statistics @@ -26,22 +26,22 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.Administrator.Role)] public class StatTemplateDistributionController : BaseApiController { - private readonly ITemplateService templateService; - private readonly IJobGroupService jobGroupService; + private readonly ITemplateRepository templateService; + private readonly IJobGroupRepository jobGroupService; private readonly IMapper mapper; private readonly IShortcodesService shortcodesService; private readonly INextRunService nextRunService; private readonly ILogger logger; - private readonly IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService; + private readonly IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService; public StatTemplateDistributionController( - ITemplateService templateService, - IJobGroupService jobGroupService, + ITemplateRepository templateService, + IJobGroupRepository jobGroupService, IMapper mapper, IShortcodesService shortcodesService, INextRunService nextRunService, ILogger logger, - IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService + IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService ) { this.templateService = templateService; diff --git a/PARR.API/Controllers/V1/Statistics/StatUnitController.cs b/PARR.API/Controllers/V1/Statistics/StatUnitController.cs index 1d593a1c..facec2ad 100644 --- a/PARR.API/Controllers/V1/Statistics/StatUnitController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatUnitController.cs @@ -7,8 +7,8 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Helpers; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.DAL.NextRunServices; -using PARR.DAL.Services.Interfaces.Unit; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1.Statistics @@ -19,11 +19,11 @@ namespace PARR.API.Controllers.V1.Statistics [Authorize(Roles = ParrRoles.Administrator.Role)] public class StatUnitController : BaseApiController { - private readonly IUnitService unitService; + private readonly IUnitRepository unitService; private readonly INextRunService nextRunService; public StatUnitController( - IUnitService unitService, + IUnitRepository unitService, INextRunService nextRunService ) { diff --git a/PARR.API/Controllers/V1/Statistics/StatUnitFieldValuesController.cs b/PARR.API/Controllers/V1/Statistics/StatUnitFieldValuesController.cs index e24fe476..b6916b96 100644 --- a/PARR.API/Controllers/V1/Statistics/StatUnitFieldValuesController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatUnitFieldValuesController.cs @@ -6,9 +6,8 @@ using PARR.API.Contracts.V1.Requests.BaseRequests; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.DAL.NextRunServices; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Unit; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1.Statistics @@ -20,14 +19,14 @@ namespace PARR.API.Controllers.V1.Statistics public class StatUnitFieldValuesController : BaseApiController { //private readonly IApplicationService applicationService; - private readonly IUnitFieldValueService unitFieldValueService; + private readonly IUnitFieldValueRepository unitFieldValueService; private readonly INextRunService nextRunService; //private readonly ICalendarService calendarService; public StatUnitFieldValuesController( //IApplicationService applicationService, - IUnitFieldValueService unitFieldValueService, + IUnitFieldValueRepository unitFieldValueService, //ICalendarService calendarService INextRunService nextRunService ) diff --git a/PARR.API/Controllers/V1/Statistics/StatWorkGroupWorkLoadController.cs b/PARR.API/Controllers/V1/Statistics/StatWorkGroupWorkLoadController.cs index 5d3d1f6d..384c54ad 100644 --- a/PARR.API/Controllers/V1/Statistics/StatWorkGroupWorkLoadController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatWorkGroupWorkLoadController.cs @@ -9,7 +9,7 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; namespace PARR.API.Controllers.V1.Statistics { @@ -18,14 +18,14 @@ namespace PARR.API.Controllers.V1.Statistics /// public class StatWorkGroupWorkLoadController : BaseApiController { - private readonly ITemplateService templateService; + private readonly ITemplateRepository templateService; private readonly IWorkLoadService workLoadService; //private readonly IWorkGroupService workGroupService; private readonly IMapper mapper; private readonly ILogger logger; public StatWorkGroupWorkLoadController( - ITemplateService templateService, + ITemplateRepository templateService, IWorkLoadService workLoadService, //IWorkGroupService workGroupService, IMapper mapper, diff --git a/PARR.API/Controllers/V1/Statistics/StatWorkWorkLoadController.cs b/PARR.API/Controllers/V1/Statistics/StatWorkWorkLoadController.cs index 81a9290a..3cac498b 100644 --- a/PARR.API/Controllers/V1/Statistics/StatWorkWorkLoadController.cs +++ b/PARR.API/Controllers/V1/Statistics/StatWorkWorkLoadController.cs @@ -1,16 +1,7 @@ using AutoMapper; -using Microsoft.AspNetCore.Mvc; -using Microsoft.EntityFrameworkCore; -using PARR.API.Contracts.V1; -using PARR.API.Contracts.V1.Requests; -using PARR.API.Contracts.V1.Requests.Queries; -using PARR.API.Contracts.V1.Responses; -using PARR.API.Contracts.V1.Responses.Base; -using PARR.API.Contracts.V1.Responses.Statistics; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; namespace PARR.API.Controllers.V1.Statistics { @@ -19,14 +10,14 @@ namespace PARR.API.Controllers.V1.Statistics /// public class StatWorkWorkLoadController : BaseApiController { - private readonly ITemplateService templateService; + private readonly ITemplateRepository templateService; private readonly IWorkLoadService workLoadService; private readonly IMapper mapper; private readonly ILogger logger; //private readonly IWorkGroupService workGroupService; public StatWorkWorkLoadController( - ITemplateService templateService, + ITemplateRepository templateService, IWorkLoadService workLoadService, IMapper mapper, ILogger logger diff --git a/PARR.API/Controllers/V1/SubprocessController.cs b/PARR.API/Controllers/V1/SubprocessController.cs index d5c2651d..c8420792 100644 --- a/PARR.API/Controllers/V1/SubprocessController.cs +++ b/PARR.API/Controllers/V1/SubprocessController.cs @@ -11,10 +11,10 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -26,14 +26,14 @@ namespace PARR.API.Controllers.V1 { private readonly ILogger logger; private readonly IMapper mapper; - private readonly ISubprocessService subprocessService; + private readonly ISubprocessRepository subprocessService; private readonly IValidator validator; private readonly IUriService uriService; public SubprocessController( ILogger logger, IMapper mapper, - ISubprocessService subprocessService, + ISubprocessRepository subprocessService, IValidator validator, IUriService uriService ) diff --git a/PARR.API/Controllers/V1/TaskStatusController.cs b/PARR.API/Controllers/V1/TaskStatusController.cs index 30a91e74..d7cb6293 100644 --- a/PARR.API/Controllers/V1/TaskStatusController.cs +++ b/PARR.API/Controllers/V1/TaskStatusController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -15,11 +15,11 @@ namespace PARR.API.Controllers.V1 public class TaskStatusController : BaseApiController { private readonly IMapper mapper; - private readonly IStatusTemplateService statusTemplateService; + private readonly IStatusTemplateRepository statusTemplateService; public TaskStatusController( IMapper mapper, - IStatusTemplateService statusTemplateService + IStatusTemplateRepository statusTemplateService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/TemplateActivatorController.cs b/PARR.API/Controllers/V1/TemplateActivatorController.cs index f6a89022..206f8d61 100644 --- a/PARR.API/Controllers/V1/TemplateActivatorController.cs +++ b/PARR.API/Controllers/V1/TemplateActivatorController.cs @@ -8,7 +8,7 @@ using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.API.Settings; using PARR.Core.Common.Interfaces.RabbitServices; -using PARR.DAL.Services.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Job; using PARR.Domain.Common.Rabbit.Messages; using PARR.Domain.Common.Roles; using PARR.Domain.Entities.Base.History; @@ -26,7 +26,7 @@ namespace PARR.API.Controllers.V1 private readonly IRabbitService mqService; private readonly IUriService uriService; private readonly MqSettings mqSettings; - private readonly IJobService jobService; + private readonly IJobRepository jobService; private readonly IClientService clientService; public TemplateActivatorController( @@ -34,7 +34,7 @@ namespace PARR.API.Controllers.V1 IRabbitService mqService, IUriService uriService, MqSettings mqSettings, - IJobService jobService, + IJobRepository jobService, IClientService clientService ) { diff --git a/PARR.API/Controllers/V1/TemplateController.cs b/PARR.API/Controllers/V1/TemplateController.cs index dfdb8dbd..038e909b 100644 --- a/PARR.API/Controllers/V1/TemplateController.cs +++ b/PARR.API/Controllers/V1/TemplateController.cs @@ -12,13 +12,13 @@ using PARR.API.Extensions; using PARR.API.Services.Interfaces; using PARR.BLL.Helpers; using PARR.Core.Common.Helpers; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.DAL.Contracts; using PARR.DAL.DomainServices.Shortcodes; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Schedule; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; using PARR.Domain.Entities.Base.History; using PARR.Domain.Enums; @@ -31,25 +31,25 @@ namespace PARR.API.Controllers.V1 public class TemplateController : BaseApiController { private readonly IMapper mapper; - private readonly ITemplateService templateService; - private readonly IRobotConfigurationService robotConfigurationService; + private readonly ITemplateRepository templateService; + private readonly IRobotConfigurationRepository robotConfigurationService; private readonly IClientService clientService; private readonly ILogger logger; private readonly IShortcodesService shortcodesService; - private readonly IOrderService orderService; + private readonly IOrderRepository orderService; private readonly SettingsFromDb settingsFromDb; - private readonly IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService; + private readonly IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService; public TemplateController( IMapper mapper, - ITemplateService templateService, - IRobotConfigurationService robotConfigurationService, + ITemplateRepository templateService, + IRobotConfigurationRepository robotConfigurationService, IClientService clientService, ILogger logger, IShortcodesService shortcodesService, - IOrderService orderService, + IOrderRepository orderService, SettingsFromDb settingsFromDb, - IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService + IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/TemplateHistoryController.cs b/PARR.API/Controllers/V1/TemplateHistoryController.cs index 5f49e34a..a68c9d9b 100644 --- a/PARR.API/Controllers/V1/TemplateHistoryController.cs +++ b/PARR.API/Controllers/V1/TemplateHistoryController.cs @@ -8,10 +8,10 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -22,11 +22,11 @@ namespace PARR.API.Controllers.V1 public class TemplateHistoryController : BaseApiController { private readonly IMapper mapper; - private readonly ITemplateHistoryService templateHistoryService; + private readonly ITemplateHistoryRepository templateHistoryService; public TemplateHistoryController( IMapper mapper, - ITemplateHistoryService templateHistoryService + ITemplateHistoryRepository templateHistoryService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/TemplateScheduleEspp.cs b/PARR.API/Controllers/V1/TemplateScheduleEspp.cs index 62f999df..a9dbe9af 100644 --- a/PARR.API/Controllers/V1/TemplateScheduleEspp.cs +++ b/PARR.API/Controllers/V1/TemplateScheduleEspp.cs @@ -8,7 +8,7 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -19,13 +19,13 @@ namespace PARR.API.Controllers.V1 [Authorize(Roles = ParrRoles.EsppRobot.RoleOrAdmin)] public class TemplateScheduleEspp : BaseApiController { - private readonly ITemplateService templateService; + private readonly ITemplateRepository templateService; private readonly IMapper mapper; private readonly IValidator validator; private readonly IUriService uriService; public TemplateScheduleEspp( - ITemplateService templateService, + ITemplateRepository templateService, IMapper mapper, IValidator validator, IUriService uriService diff --git a/PARR.API/Controllers/V1/TemplateStatusTypeController.cs b/PARR.API/Controllers/V1/TemplateStatusTypeController.cs index 52243c85..12149bb8 100644 --- a/PARR.API/Controllers/V1/TemplateStatusTypeController.cs +++ b/PARR.API/Controllers/V1/TemplateStatusTypeController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -18,11 +18,11 @@ namespace PARR.API.Controllers.V1 public class TemplateStatusTypeController : BaseApiController { private readonly IMapper mapper; - private readonly ITemplateStatusTypeService templateStatusTypeService; + private readonly ITemplateStatusTypeRepository templateStatusTypeService; public TemplateStatusTypeController( IMapper mapper, - ITemplateStatusTypeService templateStatusTypeService + ITemplateStatusTypeRepository templateStatusTypeService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/TemplateSyncStateController.cs b/PARR.API/Controllers/V1/TemplateSyncStateController.cs index 0568f956..90d72794 100644 --- a/PARR.API/Controllers/V1/TemplateSyncStateController.cs +++ b/PARR.API/Controllers/V1/TemplateSyncStateController.cs @@ -6,8 +6,8 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; +using PARR.Core.Repositories.Interfaces; using PARR.DAL.Contracts; -using PARR.DAL.Services.Interfaces; using PARR.Domain.Common.Roles; using PARR.Domain.Enums; @@ -20,14 +20,14 @@ namespace PARR.API.Controllers.V1 public class TemplateSyncStateController : BaseApiController { private readonly IMapper mapper; - private readonly ITemplateService templateService; - private readonly IRobotConfigurationService robotConfigurationService; + private readonly ITemplateRepository templateService; + private readonly IRobotConfigurationRepository robotConfigurationService; private readonly ILogger logger; public TemplateSyncStateController( IMapper mapper, - ITemplateService templateService, - IRobotConfigurationService robotConfigurationService, + ITemplateRepository templateService, + IRobotConfigurationRepository robotConfigurationService, ILogger logger ) { diff --git a/PARR.API/Controllers/V1/TestController.cs b/PARR.API/Controllers/V1/TestController.cs index 9aa20997..0c79222c 100644 --- a/PARR.API/Controllers/V1/TestController.cs +++ b/PARR.API/Controllers/V1/TestController.cs @@ -6,8 +6,8 @@ using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; using PARR.API.Settings; using PARR.Core.Common.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.DAL.NextRunServices; -using PARR.DAL.Services.Interfaces; namespace PARR.API.Controllers.V1 @@ -18,13 +18,13 @@ namespace PARR.API.Controllers.V1 private readonly IClientService clientService; private readonly IRedisCacheService redisCacheService; private readonly INextRunService nextRunService; - private readonly ITemplateService templateService; + private readonly ITemplateRepository templateService; public TestController( IClientService clientService, IRedisCacheService redisCacheService, INextRunService nextRunService, - ITemplateService templateService, + ITemplateRepository templateService, MqSettings mqSettings ) { diff --git a/PARR.API/Controllers/V1/TnkController.cs b/PARR.API/Controllers/V1/TnkController.cs index 1770fc7a..3da3a93d 100644 --- a/PARR.API/Controllers/V1/TnkController.cs +++ b/PARR.API/Controllers/V1/TnkController.cs @@ -11,10 +11,10 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -26,14 +26,14 @@ namespace PARR.API.Controllers.V1 { private readonly ILogger logger; private readonly IMapper mapper; - private readonly ITnkService tnkService; + private readonly ITnkRepository tnkService; private readonly IValidator validator; private readonly IUriService uriService; public TnkController( ILogger logger, IMapper mapper, - ITnkService tnkService, + ITnkRepository tnkService, IValidator validator, IUriService uriService ) diff --git a/PARR.API/Controllers/V1/UnitController.cs b/PARR.API/Controllers/V1/UnitController.cs index 885b69a3..92a3daa9 100644 --- a/PARR.API/Controllers/V1/UnitController.cs +++ b/PARR.API/Controllers/V1/UnitController.cs @@ -8,12 +8,11 @@ using PARR.API.Contracts.V1.Responses; 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.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities.Unit; namespace PARR.API.Controllers.V1 { @@ -21,11 +20,11 @@ namespace PARR.API.Controllers.V1 public class UnitController : BaseApiController { private readonly IMapper mapper; - private readonly IUnitService unitService; + private readonly IUnitRepository unitService; public UnitController( IMapper mapper, - IUnitService unitService + IUnitRepository unitService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/UnitFieldController.cs b/PARR.API/Controllers/V1/UnitFieldController.cs index a8f93044..d3538f2f 100644 --- a/PARR.API/Controllers/V1/UnitFieldController.cs +++ b/PARR.API/Controllers/V1/UnitFieldController.cs @@ -6,7 +6,7 @@ using PARR.API.Contracts.V1; using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Roles; namespace PARR.API.Controllers.V1 @@ -17,11 +17,11 @@ namespace PARR.API.Controllers.V1 [Authorize(Roles = ParrRoles.Administrator.Role)] public class UnitFieldController : BaseApiController { - private readonly IUnitFieldService unitFieldService; + private readonly IUnitFieldRepository unitFieldService; private readonly IMapper mapper; public UnitFieldController( - IUnitFieldService unitFieldService, + IUnitFieldRepository unitFieldService, IMapper mapper ) { diff --git a/PARR.API/Controllers/V1/UnitFieldValueController.cs b/PARR.API/Controllers/V1/UnitFieldValueController.cs index dc3583c6..a4ec7986 100644 --- a/PARR.API/Controllers/V1/UnitFieldValueController.cs +++ b/PARR.API/Controllers/V1/UnitFieldValueController.cs @@ -8,12 +8,11 @@ using PARR.API.Contracts.V1.Responses; 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.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities.Unit; namespace PARR.API.Controllers.V1 { @@ -24,13 +23,13 @@ namespace PARR.API.Controllers.V1 public class UnitFieldValueController : BaseApiController { private readonly IMapper mapper; - private readonly IUnitFieldValueService unitFieldValueService; - private readonly IUnitInValueService unitInValueService; + private readonly IUnitFieldValueRepository unitFieldValueService; + private readonly IUnitInValueRepository unitInValueService; public UnitFieldValueController( IMapper mapper, - IUnitFieldValueService unitFieldValueService, - IUnitInValueService unitInValueService + IUnitFieldValueRepository unitFieldValueService, + IUnitInValueRepository unitInValueService ) { this.mapper = mapper; diff --git a/PARR.API/Controllers/V1/UserController.cs b/PARR.API/Controllers/V1/UserController.cs index 671cfaa4..03b64fcb 100644 --- a/PARR.API/Controllers/V1/UserController.cs +++ b/PARR.API/Controllers/V1/UserController.cs @@ -11,10 +11,10 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -25,14 +25,14 @@ namespace PARR.API.Controllers.V1 public class UserController : BaseApiController { private readonly IMapper mapper; - private readonly IUserService userService; + private readonly IUserRepository userService; private readonly IValidator validator; private readonly IUriService uriService; private readonly ILogger logger; public UserController( IMapper mapper, - IUserService userService, + IUserRepository userService, IValidator validator, IUriService uriService, ILogger logger diff --git a/PARR.API/Controllers/V1/UserRoleController.cs b/PARR.API/Controllers/V1/UserRoleController.cs index ced9c526..f1b9cc48 100644 --- a/PARR.API/Controllers/V1/UserRoleController.cs +++ b/PARR.API/Controllers/V1/UserRoleController.cs @@ -8,9 +8,9 @@ using PARR.API.Contracts.V1.Responses; using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -20,18 +20,18 @@ namespace PARR.API.Controllers.V1 [Authorize(Roles = ParrRoles.Administrator.Role)] public class UserRoleController : BaseApiController { - private readonly IUserService userService; + private readonly IUserRepository userService; private readonly IMapper mapper; private readonly ILogger logger; - private readonly IRoleService roleService; + private readonly IRoleRepository roleService; private readonly IAuthService authService; private readonly IUriService uriService; public UserRoleController( - IUserService userService, + IUserRepository userService, IMapper mapper, ILogger logger, - IRoleService roleService, + IRoleRepository roleService, IAuthService authService, IUriService uriService ) diff --git a/PARR.API/Controllers/V1/WeekendController.cs b/PARR.API/Controllers/V1/WeekendController.cs index c463e7a9..6bfdfbfa 100644 --- a/PARR.API/Controllers/V1/WeekendController.cs +++ b/PARR.API/Controllers/V1/WeekendController.cs @@ -11,10 +11,10 @@ using PARR.API.Contracts.V1.Responses.Base; using PARR.API.Controllers.V1.Base; using PARR.API.Extensions; using PARR.API.Services.Interfaces; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Common.Pagination; using PARR.Domain.Common.Roles; +using PARR.Domain.Entities; namespace PARR.API.Controllers.V1 { @@ -25,13 +25,13 @@ namespace PARR.API.Controllers.V1 public class WeekendController : BaseApiController { private readonly IMapper mapper; - private readonly IWeekendDayService weekendDayService; + private readonly IWeekendDayRepository weekendDayService; private readonly IUriService uriService; private readonly IValidator validator; public WeekendController( IMapper mapper, - IWeekendDayService weekendDayService, + IWeekendDayRepository weekendDayService, IUriService uriService, IValidator validator ) diff --git a/PARR.API/MappingProfiles/DomainToResponseProfile.cs b/PARR.API/MappingProfiles/DomainToResponseProfile.cs index 540564be..a13440fc 100644 --- a/PARR.API/MappingProfiles/DomainToResponseProfile.cs +++ b/PARR.API/MappingProfiles/DomainToResponseProfile.cs @@ -2,12 +2,13 @@ using PARR.API.Authentication.Models; using PARR.API.Contracts.V1.Responses; using PARR.API.MappingProfiles.Resolvers; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.DAL.DomainModels; -using PARR.DAL.Models; -using PARR.DAL.Models.Job; -using PARR.DAL.Models.Schedule; -using PARR.DAL.Models.Unit; +using PARR.Domain.Entities; using PARR.Domain.Entities.Base.History; +using PARR.Domain.Entities.Job; +using PARR.Domain.Entities.Schedule; +using PARR.Domain.Entities.Unit; namespace PARR.API.MappingProfiles { @@ -69,7 +70,7 @@ namespace PARR.API.MappingProfiles .ForMember(d => d.Script, o => o.MapFrom(s => s.AgentScript)) .ForMember(d => d.TimeOutSec, o => o.MapFrom(s => s.AgentTimeOutSec)); - CreateMap(); + CreateMap(); #region ScheduleResponseAreaTimeOffsetResponse @@ -236,7 +237,7 @@ namespace PARR.API.MappingProfiles CreateMap(); - CreateMap(); + CreateMap(); CreateMap() .ForMember(d => d.Robot, o => o.MapFrom(s => s.Robot)) diff --git a/PARR.API/MappingProfiles/RequestToDomainProfile.cs b/PARR.API/MappingProfiles/RequestToDomainProfile.cs index 02f2c467..6a2c5b9b 100644 --- a/PARR.API/MappingProfiles/RequestToDomainProfile.cs +++ b/PARR.API/MappingProfiles/RequestToDomainProfile.cs @@ -1,8 +1,8 @@ using AutoMapper; using PARR.API.Contracts.V1.Requests; using PARR.API.Contracts.V1.Requests.Queries; -using PARR.DAL.Models.Job; using PARR.Domain.Common.Pagination; +using PARR.Domain.Entities.Job; namespace PARR.API.MappingProfiles { diff --git a/PARR.API/MappingProfiles/Resolvers/HistoryInitiatorParrComponentResolver.cs b/PARR.API/MappingProfiles/Resolvers/HistoryInitiatorParrComponentResolver.cs index 4cdf5e07..0ee8c0a8 100644 --- a/PARR.API/MappingProfiles/Resolvers/HistoryInitiatorParrComponentResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/HistoryInitiatorParrComponentResolver.cs @@ -1,16 +1,16 @@ using AutoMapper; using Microsoft.EntityFrameworkCore; using PARR.API.Contracts.V1.Responses; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Entities.Base.History; namespace PARR.API.MappingProfiles.Resolvers { public class HistoryInitiatorParrComponentResolver : IValueResolver { - private readonly IParrComponentService parrComponentService; + private readonly IParrComponentRepository parrComponentService; - public HistoryInitiatorParrComponentResolver(IParrComponentService parrComponentService) + public HistoryInitiatorParrComponentResolver(IParrComponentRepository parrComponentService) { this.parrComponentService = parrComponentService; } diff --git a/PARR.API/MappingProfiles/Resolvers/HistoryInitiatorUserResolver.cs b/PARR.API/MappingProfiles/Resolvers/HistoryInitiatorUserResolver.cs index abae719c..29765eab 100644 --- a/PARR.API/MappingProfiles/Resolvers/HistoryInitiatorUserResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/HistoryInitiatorUserResolver.cs @@ -1,16 +1,16 @@ using AutoMapper; using Microsoft.EntityFrameworkCore; using PARR.API.Contracts.V1.Responses; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; using PARR.Domain.Entities.Base.History; namespace PARR.API.MappingProfiles.Resolvers { public class HistoryInitiatorUserResolver : IValueResolver { - private readonly IUserService userService; + private readonly IUserRepository userService; - public HistoryInitiatorUserResolver(IUserService userService) + public HistoryInitiatorUserResolver(IUserRepository userService) { this.userService = userService; } diff --git a/PARR.API/MappingProfiles/Resolvers/JobGroupScheduleResolver.cs b/PARR.API/MappingProfiles/Resolvers/JobGroupScheduleResolver.cs index ad41e576..9c24d22d 100644 --- a/PARR.API/MappingProfiles/Resolvers/JobGroupScheduleResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/JobGroupScheduleResolver.cs @@ -1,26 +1,25 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.DAL.Contracts; -using PARR.DAL.Models.Job; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Schedule; +using PARR.Domain.Entities.Job; namespace PARR.API.MappingProfiles.Resolvers { public class JobGroupScheduleResolver : IValueResolver { - private readonly IEsppSchTypeConfigService esppConfigService; + private readonly IEsppSchTypeConfigRepository esppConfigService; private readonly ILogger logger; private readonly IMapper mapper; private readonly SettingsFromDb settingsFromDb; - private readonly IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService; + private readonly IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService; public JobGroupScheduleResolver( - IEsppSchTypeConfigService esppConfigService, + IEsppSchTypeConfigRepository esppConfigService, ILogger logger, IMapper mapper, SettingsFromDb settingsFromDb, - IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService + IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService ) { this.esppConfigService = esppConfigService; diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleExcludeCalendarResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleExcludeCalendarResolver.cs index 37c9ca28..b358f375 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleExcludeCalendarResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleExcludeCalendarResolver.cs @@ -1,9 +1,4 @@ -using AutoMapper; -using PARR.API.Contracts.V1.Responses; -using PARR.DAL.Contracts; -using PARR.DAL.Models; - -namespace PARR.API.MappingProfiles.Resolvers +namespace PARR.API.MappingProfiles.Resolvers { //public class RobotTaskScheduleExcludeCalendarResolver : IValueResolver //{ diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleExcludeResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleExcludeResolver.cs index 5ac8cc0f..0407b0c8 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleExcludeResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleExcludeResolver.cs @@ -1,9 +1,4 @@ -using AutoMapper; -using PARR.API.Contracts.V1.Responses; -using PARR.DAL.Contracts; -using PARR.DAL.Models; - -namespace PARR.API.MappingProfiles.Resolvers +namespace PARR.API.MappingProfiles.Resolvers { //public class RobotTaskScheduleExcludeResolver : IValueResolver //{ diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleGenerationTimeResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleGenerationTimeResolver.cs index 8d781750..c26de65f 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleGenerationTimeResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleGenerationTimeResolver.cs @@ -1,11 +1,4 @@ -using AutoMapper; -using PARR.API.Contracts.V1.Responses; -using PARR.BLL.Helpers; -using PARR.DAL.Contracts; -using PARR.DAL.Models; - - -namespace PARR.API.MappingProfiles.Resolvers +namespace PARR.API.MappingProfiles.Resolvers { //public class RobotTaskScheduleGenerationTimeResolver : IValueResolver //{ diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleNextStartResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleNextStartResolver.cs index caa71726..56449050 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleNextStartResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleNextStartResolver.cs @@ -1,11 +1,4 @@ -using AutoMapper; -using PARR.API.Contracts.V1.Responses; -using PARR.BLL.Helpers; -using PARR.DAL.Contracts; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces.Schedule; - -namespace PARR.API.MappingProfiles.Resolvers +namespace PARR.API.MappingProfiles.Resolvers { //public class RobotTaskScheduleNextStartResolver : IValueResolver //{ diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleRepeatRangeResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleRepeatRangeResolver.cs index 5cc49c57..fd4da706 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleRepeatRangeResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleRepeatRangeResolver.cs @@ -1,7 +1,7 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; using PARR.DAL.Contracts; -using PARR.DAL.Models; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleSchResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleSchResolver.cs index cf1e4958..cccb7aa5 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleSchResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleSchResolver.cs @@ -1,18 +1,18 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces.Schedule; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { public class RobotTaskScheduleSchResolver : IValueResolver?> { - private readonly IEsppSchTypeConfigService esppConfigService; + private readonly IEsppSchTypeConfigRepository esppConfigService; private readonly ILogger logger; public RobotTaskScheduleSchResolver( - IEsppSchTypeConfigService esppConfigService, + IEsppSchTypeConfigRepository esppConfigService, ILogger logger ) { diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleTimezoneResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleTimezoneResolver.cs index 2c62dfd3..dc6a497f 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleTimezoneResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskScheduleTimezoneResolver.cs @@ -1,9 +1,4 @@ -using AutoMapper; -using PARR.API.Contracts.V1.Responses; -using PARR.DAL.Contracts; -using PARR.DAL.Models; - -namespace PARR.API.MappingProfiles.Resolvers +namespace PARR.API.MappingProfiles.Resolvers { //public class RobotTaskScheduleTimezoneResolver : IValueResolver //{ diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateCategoryResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateCategoryResolver.cs index 01b3d4ac..6e4c742f 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateCategoryResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateCategoryResolver.cs @@ -1,7 +1,7 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; using PARR.DAL.Contracts; -using PARR.DAL.Models; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateClosingCodeResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateClosingCodeResolver.cs index 9e49fdc9..6af28abf 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateClosingCodeResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateClosingCodeResolver.cs @@ -1,7 +1,7 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; using PARR.DAL.Contracts; -using PARR.DAL.Models; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { diff --git a/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateInitiatorResolver.cs b/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateInitiatorResolver.cs index 9952ec8f..eb2a3c13 100644 --- a/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateInitiatorResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/RobotTaskTemplateInitiatorResolver.cs @@ -1,7 +1,7 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; using PARR.DAL.Contracts; -using PARR.DAL.Models; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { diff --git a/PARR.API/MappingProfiles/Resolvers/TemplateCategoryResolver.cs b/PARR.API/MappingProfiles/Resolvers/TemplateCategoryResolver.cs index 0c323b70..17cf0049 100644 --- a/PARR.API/MappingProfiles/Resolvers/TemplateCategoryResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/TemplateCategoryResolver.cs @@ -1,7 +1,7 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; using PARR.DAL.Contracts; -using PARR.DAL.Models; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { diff --git a/PARR.API/MappingProfiles/Resolvers/TemplateClosingCodeResolver.cs b/PARR.API/MappingProfiles/Resolvers/TemplateClosingCodeResolver.cs index a4105ffb..2fd95d47 100644 --- a/PARR.API/MappingProfiles/Resolvers/TemplateClosingCodeResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/TemplateClosingCodeResolver.cs @@ -1,7 +1,7 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; using PARR.DAL.Contracts; -using PARR.DAL.Models; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { diff --git a/PARR.API/MappingProfiles/Resolvers/TemplateInitiatorResolver.cs b/PARR.API/MappingProfiles/Resolvers/TemplateInitiatorResolver.cs index 03302ba6..e1e3935b 100644 --- a/PARR.API/MappingProfiles/Resolvers/TemplateInitiatorResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/TemplateInitiatorResolver.cs @@ -1,7 +1,7 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; using PARR.DAL.Contracts; -using PARR.DAL.Models; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { diff --git a/PARR.API/MappingProfiles/Resolvers/TemplateScheduleResolver.cs b/PARR.API/MappingProfiles/Resolvers/TemplateScheduleResolver.cs index 465a843b..3f7ba436 100644 --- a/PARR.API/MappingProfiles/Resolvers/TemplateScheduleResolver.cs +++ b/PARR.API/MappingProfiles/Resolvers/TemplateScheduleResolver.cs @@ -1,26 +1,25 @@ using AutoMapper; using PARR.API.Contracts.V1.Responses; +using PARR.Core.Repositories.Interfaces.Schedule; using PARR.DAL.Contracts; -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Schedule; +using PARR.Domain.Entities; namespace PARR.API.MappingProfiles.Resolvers { public class TemplateScheduleResolver : IValueResolver { - private readonly IEsppSchTypeConfigService esppConfigService; + private readonly IEsppSchTypeConfigRepository esppConfigService; private readonly ILogger logger; private readonly IMapper mapper; private readonly SettingsFromDb settingsFromDb; - private readonly IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService; + private readonly IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService; public TemplateScheduleResolver( - IEsppSchTypeConfigService esppConfigService, + IEsppSchTypeConfigRepository esppConfigService, ILogger logger, IMapper mapper, SettingsFromDb settingsFromDb, - IScheduleResponseAreaTimeOffsetService scheduleResponseAreaTimeOffsetService + IScheduleResponseAreaTimeOffsetRepository scheduleResponseAreaTimeOffsetService ) { this.esppConfigService = esppConfigService; diff --git a/PARR.API/Program.cs b/PARR.API/Program.cs index 28a7333d..756206de 100644 --- a/PARR.API/Program.cs +++ b/PARR.API/Program.cs @@ -24,7 +24,7 @@ builder.Host.UseSerilog((context, config) => builder.Services.InstallSettings(builder.Configuration); // Add services to the container. -builder.Services.InstallDalServices(builder.Configuration); +builder.Services.AddDalServices(builder.Configuration); //---- new ---- builder.Services.AddCoreServices(builder.Configuration); builder.Services.AddTaskManagement(mqSettingsFactory: (provider, taskType) => diff --git a/PARR.API/Services/Implementations/AuthService.cs b/PARR.API/Services/Implementations/AuthService.cs index e9fd1ebf..0c47daf4 100644 --- a/PARR.API/Services/Implementations/AuthService.cs +++ b/PARR.API/Services/Implementations/AuthService.cs @@ -4,8 +4,8 @@ using PARR.API.Domain.InfluxDbModels; using PARR.API.Services.Interfaces; using PARR.API.Settings; using PARR.Core.Common.Interfaces; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.Domain.Common.Roles; using PARR.Domain.Settings; @@ -14,21 +14,21 @@ namespace PARR.API.Services.Implementations public class AuthService : IAuthService { private readonly IRedisCacheService cacheService; - private readonly IUserService userService; + private readonly IUserRepository userService; private readonly UserCacheSettings userCacheSettings; private readonly IClientService clientService; private readonly IInfluxDbService influxDbService; private readonly InfluxDbSettings influxDbSettings; - private readonly IUnitService unitService; + private readonly IUnitRepository unitService; public AuthService( IRedisCacheService cacheService, - IUserService userService, + IUserRepository userService, UserCacheSettings userCacheSettings, IClientService clientService, IInfluxDbService influxDbService, InfluxDbSettings influxDbSettings, - IUnitService unitService + IUnitRepository unitService ) { this.cacheService = cacheService; diff --git a/PARR.API/Services/Interfaces/IWorkLoadService.cs b/PARR.API/Services/Interfaces/IWorkLoadService.cs index 36ae14e6..f0ce584c 100644 --- a/PARR.API/Services/Interfaces/IWorkLoadService.cs +++ b/PARR.API/Services/Interfaces/IWorkLoadService.cs @@ -1,7 +1,4 @@ -using PARR.API.Contracts.V1.Requests.Queries; -using PARR.DAL.Models; - -namespace PARR.API.Services.Interfaces +namespace PARR.API.Services.Interfaces { /// /// Сервисы по формированию статистики загрузки рабочих групп/ЗО, и тд регламентными работами diff --git a/PARR.API/Validators/DistributeRequestValidator.cs b/PARR.API/Validators/DistributeRequestValidator.cs index f7826eae..36625915 100644 --- a/PARR.API/Validators/DistributeRequestValidator.cs +++ b/PARR.API/Validators/DistributeRequestValidator.cs @@ -1,13 +1,13 @@ using FluentValidation; using Microsoft.EntityFrameworkCore; using PARR.API.Contracts.V1.Requests; -using PARR.DAL.Services.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Job; namespace PARR.API.Validators { public class DistributeRequestValidator : AbstractValidator { - public DistributeRequestValidator(IJobGroupService jobGroupService) + public DistributeRequestValidator(IJobGroupRepository jobGroupService) { RuleFor(t => t.JobGroupId).NotEmpty().MustAsync(async (entity, value, c) => { diff --git a/PARR.API/Validators/JobGroupValidator.cs b/PARR.API/Validators/JobGroupValidator.cs index 993459f7..fd96b693 100644 --- a/PARR.API/Validators/JobGroupValidator.cs +++ b/PARR.API/Validators/JobGroupValidator.cs @@ -1,12 +1,10 @@ using FluentValidation; using Microsoft.EntityFrameworkCore; -using Newtonsoft.Json.Linq; using PARR.API.Contracts.V1.Requests; -using PARR.DAL.Contracts; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Job; -using PARR.DAL.Services.Interfaces.Schedule; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Schedule; +using PARR.Core.Repositories.Interfaces.Unit; using PARR.Domain.Enums; namespace PARR.API.Validators @@ -14,11 +12,11 @@ namespace PARR.API.Validators public class JobGroupValidator : AbstractValidator { public JobGroupValidator( - IJobGroupTypeService jobGroupTypeService, - IUnitFieldService unitFieldService, - IScheduleExcludeTypeService scheduleExcludeTypeService, - IScheduleExcludeTypeCalendarService scheduleExcludeTypeCalendarService, - IDistributionPeriodService distributionPeriodService + IJobGroupTypeRepository jobGroupTypeService, + IUnitFieldRepository unitFieldService, + IScheduleExcludeTypeRepository scheduleExcludeTypeService, + IScheduleExcludeTypeCalendarRepository scheduleExcludeTypeCalendarService, + IDistributionPeriodRepository distributionPeriodService ) { RuleFor(t => t.Name) diff --git a/PARR.API/Validators/JobRequestValidator.cs b/PARR.API/Validators/JobRequestValidator.cs index dd461aac..bff166d3 100644 --- a/PARR.API/Validators/JobRequestValidator.cs +++ b/PARR.API/Validators/JobRequestValidator.cs @@ -1,25 +1,25 @@ using FluentValidation; using PARR.API.Contracts.V1.Requests; -using PARR.DAL.Models.Job; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Job; -using PARR.DAL.Services.Interfaces.Unit; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Job; +using PARR.Core.Repositories.Interfaces.Unit; +using PARR.Domain.Entities.Job; namespace PARR.API.Validators { public class JobRequestValidator : AbstractValidator { - private readonly ITnkService tnkService; - private readonly IJobGroupService jobGroupService; - private readonly IJobService jobService; - private readonly IUnitFieldService unitFieldService; + private readonly ITnkRepository tnkService; + private readonly IJobGroupRepository jobGroupService; + private readonly IJobRepository jobService; + private readonly IUnitFieldRepository unitFieldService; private JobGroup? jobGroup; public JobRequestValidator( - ITnkService tnkService, - IJobGroupService jobGroupService, - IJobService jobService, - IUnitFieldService unitFieldService + ITnkRepository tnkService, + IJobGroupRepository jobGroupService, + IJobRepository jobService, + IUnitFieldRepository unitFieldService ) { this.tnkService = tnkService; diff --git a/PARR.API/Validators/SubprocessValidator.cs b/PARR.API/Validators/SubprocessValidator.cs index 62ab383d..9aad1a84 100644 --- a/PARR.API/Validators/SubprocessValidator.cs +++ b/PARR.API/Validators/SubprocessValidator.cs @@ -1,16 +1,16 @@ using FluentValidation; using PARR.API.Contracts.V1.Requests; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; namespace PARR.API.Validators { public class SubprocessValidator : AbstractValidator { - private readonly IProcessService processService; + private readonly IProcessRepository processService; private bool? isValid = null; public SubprocessValidator( - IProcessService processService + IProcessRepository processService ) { this.processService = processService; diff --git a/PARR.API/Validators/TemplateActivatorRequestValidator.cs b/PARR.API/Validators/TemplateActivatorRequestValidator.cs index ce908f9f..05519417 100644 --- a/PARR.API/Validators/TemplateActivatorRequestValidator.cs +++ b/PARR.API/Validators/TemplateActivatorRequestValidator.cs @@ -1,7 +1,7 @@ using FluentValidation; using PARR.API.Contracts.V1.Requests; -using PARR.DAL.Services.Interfaces; -using PARR.DAL.Services.Interfaces.Job; +using PARR.Core.Repositories.Interfaces; +using PARR.Core.Repositories.Interfaces.Job; using PARR.Domain.Enums; namespace PARR.API.Validators @@ -9,9 +9,9 @@ namespace PARR.API.Validators public class TemplateActivatorRequestValidator : AbstractValidator { public TemplateActivatorRequestValidator( - ITemplateService templateService, - IJobService jobService, - IJobGroupService jobGroupService + ITemplateRepository templateService, + IJobRepository jobService, + IJobGroupRepository jobGroupService ) { RuleFor(t => t.EntityType).Must(type => diff --git a/PARR.API/Validators/TnkRequestValidator.cs b/PARR.API/Validators/TnkRequestValidator.cs index 1fbfba89..757376de 100644 --- a/PARR.API/Validators/TnkRequestValidator.cs +++ b/PARR.API/Validators/TnkRequestValidator.cs @@ -1,16 +1,16 @@ using FluentValidation; using PARR.API.Contracts.V1.Requests; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; namespace PARR.API.Validators { public class TnkRequestValidator : AbstractValidator { - private readonly ISubprocessService subprocessService; + private readonly ISubprocessRepository subprocessService; private bool? isValid = null; public TnkRequestValidator( - ISubprocessService subprocessService + ISubprocessRepository subprocessService ) { this.subprocessService = subprocessService; diff --git a/PARR.API/Validators/WeekendRequestValidator.cs b/PARR.API/Validators/WeekendRequestValidator.cs index 22978f6d..0e592191 100644 --- a/PARR.API/Validators/WeekendRequestValidator.cs +++ b/PARR.API/Validators/WeekendRequestValidator.cs @@ -1,15 +1,15 @@ using FluentValidation; using Microsoft.EntityFrameworkCore; using PARR.API.Contracts.V1.Requests; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; namespace PARR.API.Validators { public class WeekendRequestValidator : AbstractValidator { - private readonly IWeekendDayService weekendDayService; + private readonly IWeekendDayRepository weekendDayService; - public WeekendRequestValidator(IWeekendDayService weekendDayService) + public WeekendRequestValidator(IWeekendDayRepository weekendDayService) { this.weekendDayService = weekendDayService; diff --git a/PARR.API/Validators/WorkRequestValidator.cs b/PARR.API/Validators/WorkRequestValidator.cs index b3d5683a..e455f873 100644 --- a/PARR.API/Validators/WorkRequestValidator.cs +++ b/PARR.API/Validators/WorkRequestValidator.cs @@ -1,17 +1,17 @@ using FluentValidation; using PARR.API.Contracts.V1.Requests; -using PARR.DAL.Services.Interfaces; +using PARR.Core.Repositories.Interfaces; namespace PARR.API.Validators { public class WorkRequestValidator : AbstractValidator { - private readonly ITnkService tnkService; + private readonly ITnkRepository tnkService; private bool? isValid = null; public WorkRequestValidator( - ITnkService tnkService + ITnkRepository tnkService //ITemplateMaskValidator templateMaskValidator ) { diff --git a/PARR.Core/Repositories/Interfaces/IAgentHistoryRepository.cs b/PARR.Core/Repositories/Interfaces/IAgentHistoryRepository.cs new file mode 100644 index 00000000..bd0c3671 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IAgentHistoryRepository.cs @@ -0,0 +1,9 @@ +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IAgentHistoryRepository : IBaseRepository + { + } +} diff --git a/PARR.Core/Repositories/Interfaces/IDistributionPeriodRepository.cs b/PARR.Core/Repositories/Interfaces/IDistributionPeriodRepository.cs new file mode 100644 index 00000000..7a117e83 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IDistributionPeriodRepository.cs @@ -0,0 +1,9 @@ +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IDistributionPeriodRepository : IBaseRepository + { + } +} diff --git a/PARR.Core/Repositories/Interfaces/IOrderRepository.cs b/PARR.Core/Repositories/Interfaces/IOrderRepository.cs new file mode 100644 index 00000000..83431fb5 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IOrderRepository.cs @@ -0,0 +1,9 @@ +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IOrderRepository : IBaseRepository + { + } +} diff --git a/PARR.DAL/Services/Interfaces/IOrderStatusService.cs b/PARR.Core/Repositories/Interfaces/IOrderStatusRepository.cs similarity index 52% rename from PARR.DAL/Services/Interfaces/IOrderStatusService.cs rename to PARR.Core/Repositories/Interfaces/IOrderStatusRepository.cs index c2fc96a3..d2a9be7c 100644 --- a/PARR.DAL/Services/Interfaces/IOrderStatusService.cs +++ b/PARR.Core/Repositories/Interfaces/IOrderStatusRepository.cs @@ -1,10 +1,9 @@ -using PARR.DAL.Contracts; -using PARR.DAL.Models; +using PARR.Domain.Entities; using PARR.Domain.Enums; -namespace PARR.DAL.Services.Interfaces +namespace PARR.Core.Repositories.Interfaces { - public interface IOrderStatusService + public interface IOrderStatusRepository { IQueryable Get(); OrderStatusEnum GetOrderStatusByName(string statusName); diff --git a/PARR.Core/Repositories/Interfaces/IParrComponentRepository.cs b/PARR.Core/Repositories/Interfaces/IParrComponentRepository.cs new file mode 100644 index 00000000..6d5ae10f --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IParrComponentRepository.cs @@ -0,0 +1,9 @@ +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IParrComponentRepository + { + IQueryable Get(); + } +} diff --git a/PARR.Core/Repositories/Interfaces/IProcessRepository.cs b/PARR.Core/Repositories/Interfaces/IProcessRepository.cs new file mode 100644 index 00000000..f735f1e7 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IProcessRepository.cs @@ -0,0 +1,9 @@ +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IProcessRepository : IBaseRepository + { + } +} diff --git a/PARR.DAL/Services/Interfaces/IRobotConfigurationService.cs b/PARR.Core/Repositories/Interfaces/IRobotConfigurationRepository.cs similarity index 91% rename from PARR.DAL/Services/Interfaces/IRobotConfigurationService.cs rename to PARR.Core/Repositories/Interfaces/IRobotConfigurationRepository.cs index 05a8edac..06b019c8 100644 --- a/PARR.DAL/Services/Interfaces/IRobotConfigurationService.cs +++ b/PARR.Core/Repositories/Interfaces/IRobotConfigurationRepository.cs @@ -1,10 +1,10 @@ -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces.Base; +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; using PARR.Domain.Enums; -namespace PARR.DAL.Services.Interfaces +namespace PARR.Core.Repositories.Interfaces { - public interface IRobotConfigurationService : IBaseService + public interface IRobotConfigurationRepository : IBaseRepository { /// /// Обновить статус работы робота diff --git a/PARR.Core/Repositories/Interfaces/IRobotHistoryLevelRepository.cs b/PARR.Core/Repositories/Interfaces/IRobotHistoryLevelRepository.cs new file mode 100644 index 00000000..7099934f --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IRobotHistoryLevelRepository.cs @@ -0,0 +1,9 @@ +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IRobotHistoryLevelRepository + { + IQueryable Get(); + } +} diff --git a/PARR.Core/Repositories/Interfaces/IRobotHistoryRepository.cs b/PARR.Core/Repositories/Interfaces/IRobotHistoryRepository.cs new file mode 100644 index 00000000..755f501c --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IRobotHistoryRepository.cs @@ -0,0 +1,9 @@ +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IRobotHistoryRepository : IBaseRepository + { + } +} diff --git a/PARR.Core/Repositories/Interfaces/IRobotRepository.cs b/PARR.Core/Repositories/Interfaces/IRobotRepository.cs new file mode 100644 index 00000000..be9fff60 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IRobotRepository.cs @@ -0,0 +1,9 @@ +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IRobotRepository + { + IQueryable Get(); + } +} diff --git a/PARR.Core/Repositories/Interfaces/IRobotStatusRepository.cs b/PARR.Core/Repositories/Interfaces/IRobotStatusRepository.cs new file mode 100644 index 00000000..921e7996 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IRobotStatusRepository.cs @@ -0,0 +1,9 @@ +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IRobotStatusRepository + { + IQueryable Get(); + } +} diff --git a/PARR.Core/Repositories/Interfaces/IRoleRepository.cs b/PARR.Core/Repositories/Interfaces/IRoleRepository.cs new file mode 100644 index 00000000..95d7e370 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IRoleRepository.cs @@ -0,0 +1,9 @@ +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface IRoleRepository : IBaseRepository + { + } +} diff --git a/PARR.Core/Repositories/Interfaces/IStatusTemplateRepository.cs b/PARR.Core/Repositories/Interfaces/IStatusTemplateRepository.cs new file mode 100644 index 00000000..0167027d --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/IStatusTemplateRepository.cs @@ -0,0 +1,7 @@ +namespace PARR.Core.Repositories.Interfaces +{ + public interface IStatusTemplateRepository + { + IQueryable Get(); + } +} diff --git a/PARR.Core/Repositories/Interfaces/ISubprocessRepository.cs b/PARR.Core/Repositories/Interfaces/ISubprocessRepository.cs new file mode 100644 index 00000000..3c717211 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/ISubprocessRepository.cs @@ -0,0 +1,9 @@ +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface ISubprocessRepository : IBaseRepository + { + } +} diff --git a/PARR.Core/Repositories/Interfaces/ITaskStatusRepository.cs b/PARR.Core/Repositories/Interfaces/ITaskStatusRepository.cs new file mode 100644 index 00000000..43e73ff1 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/ITaskStatusRepository.cs @@ -0,0 +1,7 @@ +namespace PARR.Core.Repositories.Interfaces +{ + public interface ITaskStatusRepository + { + IQueryable Get(); + } +} diff --git a/PARR.Core/Repositories/Interfaces/ITemplateHistoryRepository.cs b/PARR.Core/Repositories/Interfaces/ITemplateHistoryRepository.cs new file mode 100644 index 00000000..5427acd8 --- /dev/null +++ b/PARR.Core/Repositories/Interfaces/ITemplateHistoryRepository.cs @@ -0,0 +1,9 @@ +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; + +namespace PARR.Core.Repositories.Interfaces +{ + public interface ITemplateHistoryRepository : IBaseRepository + { + } +} diff --git a/PARR.DAL/Services/Interfaces/ITemplateService.cs b/PARR.Core/Repositories/Interfaces/ITemplateRepository.cs similarity index 85% rename from PARR.DAL/Services/Interfaces/ITemplateService.cs rename to PARR.Core/Repositories/Interfaces/ITemplateRepository.cs index 68bdfe12..67389abc 100644 --- a/PARR.DAL/Services/Interfaces/ITemplateService.cs +++ b/PARR.Core/Repositories/Interfaces/ITemplateRepository.cs @@ -1,10 +1,10 @@ -using PARR.DAL.Models; -using PARR.DAL.Services.Interfaces.Base; +using PARR.Core.Repositories.Base; +using PARR.Domain.Entities; using PARR.Domain.Entities.Base.History; -namespace PARR.DAL.Services.Interfaces +namespace PARR.Core.Repositories.Interfaces { - public interface ITemplateService : IBaseService