From 537891b8c5ec1006ea67de539243faa16c7627f3 Mon Sep 17 00:00:00 2001 From: TekH Date: Fri, 18 Jul 2025 16:10:39 +0200 Subject: [PATCH] refactor(ProfileService): CRUDService-Implementierung entfernen --- .../Contracts/IProfileObjStateService.cs | 15 +++++++-------- .../Contracts/IProfileService.cs | 9 ++------- .../Services/ProfileObjStateService.cs | 4 ++-- .../Services/ProfileService.cs | 13 ++----------- 4 files changed, 13 insertions(+), 28 deletions(-) diff --git a/src/WorkFlow.Application/Contracts/IProfileObjStateService.cs b/src/WorkFlow.Application/Contracts/IProfileObjStateService.cs index 9893966..f751b5f 100644 --- a/src/WorkFlow.Application/Contracts/IProfileObjStateService.cs +++ b/src/WorkFlow.Application/Contracts/IProfileObjStateService.cs @@ -3,13 +3,12 @@ using DigitalData.Core.DTO; using WorkFlow.Application.DTO.ProfileObjState; using WorkFlow.Domain.Entities; -namespace WorkFlow.Application.Contracts +namespace WorkFlow.Application.Contracts; + +public interface IProfileObjStateService : ICRUDService { - public interface IProfileObjStateService : ICRUDService - { - Task>> ReadAsync( - bool withProfile = true, bool withUser = true, bool withState = true, - int? userId = null, string? username = null, - int? profileId = null, int? objId = null, bool? profileActive = null); - } + Task>> ReadAsync( + bool withProfile = true, bool withUser = true, bool withState = true, + int? userId = null, string? username = null, + int? profileId = null, int? objId = null); } \ No newline at end of file diff --git a/src/WorkFlow.Application/Contracts/IProfileService.cs b/src/WorkFlow.Application/Contracts/IProfileService.cs index 3b55fda..ed70131 100644 --- a/src/WorkFlow.Application/Contracts/IProfileService.cs +++ b/src/WorkFlow.Application/Contracts/IProfileService.cs @@ -1,10 +1,5 @@ -using DigitalData.Core.Abstractions.Application; -using WorkFlow.Application.DTO.Profile; -using WorkFlow.Domain.Entities; +namespace WorkFlow.Application.Contracts; -namespace WorkFlow.Application.Contracts +public interface IProfileService { - public interface IProfileService : ICRUDService - { - } } \ No newline at end of file diff --git a/src/WorkFlow.Application/Services/ProfileObjStateService.cs b/src/WorkFlow.Application/Services/ProfileObjStateService.cs index bde4e78..087eb1a 100644 --- a/src/WorkFlow.Application/Services/ProfileObjStateService.cs +++ b/src/WorkFlow.Application/Services/ProfileObjStateService.cs @@ -19,13 +19,13 @@ public class ProfileObjStateService : CRUDService>> ReadAsync( bool withProfile = true, bool withUser = true, bool withState = true, int? userId = null, string? username = null, - int? profileId = null, int? objId = null, bool? profileActive = null) + int? profileId = null, int? objId = null) { var pos_list = await _repository.ReadAsync( isReadonly: true, withProfile: withProfile, withUser: withUser, withState: withState, userId: userId, username: username, - profileId: profileId, objId: objId, profileActive: profileActive); + profileId: profileId, objId: objId); var post_dto_list = _mapper.Map>(pos_list); diff --git a/src/WorkFlow.Application/Services/ProfileService.cs b/src/WorkFlow.Application/Services/ProfileService.cs index cd21475..cc9e173 100644 --- a/src/WorkFlow.Application/Services/ProfileService.cs +++ b/src/WorkFlow.Application/Services/ProfileService.cs @@ -1,16 +1,7 @@ -using DigitalData.Core.Abstractions.Application; -using DigitalData.Core.Application; -using WorkFlow.Application.Contracts; -using WorkFlow.Application.DTO.Profile; -using WorkFlow.Domain.Entities; -using WorkFlow.Infrastructure.Contracts; +using WorkFlow.Application.Contracts; namespace WorkFlow.Application.Services; -public class ProfileService : CRUDService, - IProfileService, ICRUDService +public class ProfileService : IProfileService { - public ProfileService(IProfileRepository repository, AutoMapper.IMapper mapper) : base(repository, mapper) - { - } } \ No newline at end of file