Refaktorisierung der Lokalisierung und DTO-Integration
- Ersetzung von ITranslateService durch IStringLocalizer<X> für verbesserte Lokalisierung. - Aktualisierung der DTO-Klassen entsprechend der neuesten Core.DTO-Struktur. - Integration der neuen Klassen Result und DataResult aus Core.DTO für standardisierte Serviceantworten.
This commit is contained in:
@@ -0,0 +1,4 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.Auth
|
||||
{
|
||||
public record AuthCheckDto (bool IsAuthenticated);
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.Auth
|
||||
{
|
||||
public record LogInDto(string Username, string Password);
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.Group
|
||||
{
|
||||
public record DirectoryGroupDto
|
||||
(
|
||||
IEnumerable<string> Samaccountname
|
||||
//public string Name { get; set; }
|
||||
//public string ObjectSid { get; set; }
|
||||
//public string ObjectCategory { get; set; }
|
||||
//public int SamAccountType { get; set; }
|
||||
//public string DistinguishedName { get; set; }
|
||||
//public int InstanceType { get; set; }
|
||||
//public string CN { get; set; }
|
||||
//public string ObjectClass { get; set; }
|
||||
//public DateTime WhenChanged { get; set; }
|
||||
//public Guid ObjectGuid { get; set; }
|
||||
//public long UsnCreated { get; set; }
|
||||
//public int? GroupType { get; set; }
|
||||
//public DateTime? DsCorePropagationData { get; set; }
|
||||
//public int? AdminCount { get; set; }
|
||||
//public int? SystemFlags { get; set; }
|
||||
//public string Member { get; set; }
|
||||
//public string AdsPath { get; set; }
|
||||
//public long UsnChanged { get; set; }
|
||||
//public DateTime WhenCreated { get; set; }
|
||||
//public string Description { get; set; }
|
||||
//public bool? IsCriticalSystemObject { get; set; }
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.Group
|
||||
{
|
||||
public record GroupCreateDto
|
||||
(
|
||||
string? Name,
|
||||
bool? AdSync,
|
||||
bool? Internal,
|
||||
bool? Active,
|
||||
string? Comment,
|
||||
string? AddedWho,
|
||||
string? ChangedWho
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.Group
|
||||
{
|
||||
public record GroupReadDto
|
||||
(
|
||||
int Guid,
|
||||
string? Name,
|
||||
bool? AdSync,
|
||||
bool? Internal,
|
||||
bool? Active,
|
||||
string? Comment,
|
||||
string? AddedWho,
|
||||
string? ChangedWho
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.Group
|
||||
{
|
||||
public record GroupUpdateDto
|
||||
(
|
||||
int Guid,
|
||||
string? Name,
|
||||
bool? AdSync,
|
||||
bool? Internal,
|
||||
bool? Active,
|
||||
string? Comment,
|
||||
string? ChangedWho
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.GroupOfUser
|
||||
{
|
||||
public record GroupOfUserCreateDto(
|
||||
int UserId,
|
||||
int GroupId,
|
||||
string? Comment,
|
||||
string? AddedWho
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
using DigitalData.UserManager.DataContracts.DTOs.Group;
|
||||
using DigitalData.UserManager.DataContracts.DTOs.User;
|
||||
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.GroupOfUser
|
||||
{
|
||||
public record GroupOfUserReadDto(
|
||||
int Guid,
|
||||
int UserId,
|
||||
int GroupId,
|
||||
string? Comment,
|
||||
string AddedWho,
|
||||
string? ChangedWho,
|
||||
UserReadDto User,
|
||||
GroupReadDto Group
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.GroupOfUser
|
||||
{
|
||||
public record GroupOfUserUpdateDto(
|
||||
int Guid,
|
||||
int? UserId,
|
||||
int? GroupId,
|
||||
string? Comment,
|
||||
string? ChangedWho
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.Module
|
||||
{
|
||||
public record ModuleDto(
|
||||
int Guid,
|
||||
string? Name,
|
||||
string? ShortName
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.ModuleOfUser
|
||||
{
|
||||
public record ModuleOfUserCreateDto(
|
||||
int UserId,
|
||||
int ModuleId,
|
||||
bool IsAdmin,
|
||||
string? Comment,
|
||||
string? AddedWho
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.ModuleOfUser
|
||||
{
|
||||
public record ModuleOfUserReadDto(
|
||||
int Guid,
|
||||
int UserId,
|
||||
int ModuleId,
|
||||
string? Comment,
|
||||
string? AddedWho,
|
||||
string? ChangedWho
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.ModuleOfUser
|
||||
{
|
||||
public record ModuleOfUserUpdateDto(
|
||||
int Guid,
|
||||
int UserId,
|
||||
int ModuleId,
|
||||
bool? IsAdmin,
|
||||
string? Comment,
|
||||
string? ChangedWho
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs
|
||||
{
|
||||
public record SearchRootCreateDto(string? DirEntryUsername, string DirEntryPassword);
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.User
|
||||
{
|
||||
public record class UserCreateDto
|
||||
{
|
||||
public string? Prename { get; init; }
|
||||
public string? Name { get; init; }
|
||||
public string? Username { get; init; }
|
||||
public string? Shortname { get; init; }
|
||||
public string? Email { get; init; }
|
||||
public string Language { get; init; } = "de-DE";
|
||||
public string? Comment { get; init; }
|
||||
public bool? Deleted { get; init; }
|
||||
public string DateFormat { get; init; } = "dd.MM.yyyy";
|
||||
public string AddedWho { get; init; } = "DEFAULT";
|
||||
public string? ChangedWho { get; init; }
|
||||
public bool Active { get; init; } = true;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.User
|
||||
{
|
||||
public record UserPrincipalDto
|
||||
(
|
||||
string SamAccountName,
|
||||
string GivenName,
|
||||
string? MiddleName,
|
||||
string Surname,
|
||||
string EmailAddress,
|
||||
string? AddedWho,
|
||||
string? DateFormat
|
||||
// Guid Guid,
|
||||
// string SId,
|
||||
// string EmployeeId,
|
||||
// string VoiceTelephoneNumber,
|
||||
// DateTime? AccountExpirationDate,
|
||||
// DateTime? AccountLockoutTime,
|
||||
// bool AllowReversiblePasswordEncryption,
|
||||
// int BadLogonCount,
|
||||
// bool DelegationPermitted,
|
||||
// bool? Enabled,
|
||||
// string HomeDirectory,
|
||||
// string HomeDrive,
|
||||
// DateTime? LastBadPasswordAttempt,
|
||||
// DateTime? LastLogon,
|
||||
// DateTime? LastPasswordSet,
|
||||
// bool PasswordNeverExpires,
|
||||
// bool PasswordNotRequired,
|
||||
// byte[] PermittedLogonTimes,
|
||||
// bool SmartcardLogonRequired,
|
||||
// bool UserCannotChangePassword
|
||||
);
|
||||
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.User
|
||||
{
|
||||
public record UserPrincipalReadDto
|
||||
(
|
||||
Guid Guid,
|
||||
string SId,
|
||||
string EmployeeId,
|
||||
string SamAccountName,
|
||||
string GivenName,
|
||||
string MiddleName,
|
||||
string Surname,
|
||||
string EmailAddress
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.User
|
||||
{
|
||||
public record UserReadDto(
|
||||
int Guid,
|
||||
string? Prename,
|
||||
string? Name,
|
||||
string Username,
|
||||
string? Shortname,
|
||||
string? Email,
|
||||
string Language,
|
||||
string? Comment,
|
||||
bool Deleted,
|
||||
string DateFormat,
|
||||
string AddedWho,
|
||||
bool Active
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.User
|
||||
{
|
||||
public record UserUpdateDto(
|
||||
int Guid,
|
||||
string? Prename,
|
||||
string? Name,
|
||||
string? Username,
|
||||
string? Shortname,
|
||||
string? Email,
|
||||
string? Language,
|
||||
string? Comment,
|
||||
bool? Deleted,
|
||||
string? DateFormat,
|
||||
string? AddedWho,
|
||||
string? ChangedWho,
|
||||
bool? Active
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.UserRep
|
||||
{
|
||||
public record UserRepCreateDto(
|
||||
int UserId,
|
||||
int? RepGroupId,
|
||||
int RightGroupId,
|
||||
string AddedWho,
|
||||
int RepUserId
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
using DigitalData.UserManager.DataContracts.DTOs.Group;
|
||||
using DigitalData.UserManager.DataContracts.DTOs.User;
|
||||
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.UserRep
|
||||
{
|
||||
public record UserRepReadDto(
|
||||
int Guid,
|
||||
int UserId,
|
||||
int? RepGroupId,
|
||||
int RightGroupId,
|
||||
string AddedWho,
|
||||
int? RepUserId,
|
||||
UserReadDto? User,
|
||||
GroupReadDto? RepGroup,
|
||||
GroupReadDto? RightGroup,
|
||||
UserReadDto? RepUser
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
namespace DigitalData.UserManager.DataContracts.DTOs.UserRep
|
||||
{
|
||||
public record UserRepUpdateDto(
|
||||
int UserId,
|
||||
int? RepGroupId,
|
||||
int RightGroupId,
|
||||
int RepUserId
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user